Skip to content

Commit 38a08cc

Browse files
probonopdCopilot
andauthored
Update src/runtime/runtime.c
Co-authored-by: Copilot <[email protected]>
1 parent f66ad0d commit 38a08cc

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/runtime/runtime.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1865,7 +1865,10 @@ int main(int argc, char* argv[]) {
18651865
} else {
18661866
/* Parent process - wait for AppRun to finish, then close pipe */
18671867
int status;
1868-
pid_t waited_pid = waitpid(apprun_pid, &status, 0);
1868+
pid_t waited_pid;
1869+
do {
1870+
waited_pid = waitpid(apprun_pid, &status, 0);
1871+
} while (waited_pid == -1 && errno == EINTR);
18691872
if (waited_pid == -1) {
18701873
perror("waitpid error");
18711874
close(keepalive_pipe[0]);

0 commit comments

Comments
 (0)