diff options
Diffstat (limited to 'src/process.c')
| -rw-r--r-- | src/process.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/src/process.c b/src/process.c index 975d92f36f1..f6990c2ff19 100644 --- a/src/process.c +++ b/src/process.c | |||
| @@ -6486,7 +6486,7 @@ sigchld_handler (signo) | |||
| 6486 | 6486 | ||
| 6487 | while (1) | 6487 | while (1) |
| 6488 | { | 6488 | { |
| 6489 | register EMACS_INT pid; | 6489 | pid_t pid; |
| 6490 | WAITTYPE w; | 6490 | WAITTYPE w; |
| 6491 | Lisp_Object tail; | 6491 | Lisp_Object tail; |
| 6492 | 6492 | ||
| @@ -6530,11 +6530,15 @@ sigchld_handler (signo) | |||
| 6530 | /* Find the process that signaled us, and record its status. */ | 6530 | /* Find the process that signaled us, and record its status. */ |
| 6531 | 6531 | ||
| 6532 | /* The process can have been deleted by Fdelete_process. */ | 6532 | /* The process can have been deleted by Fdelete_process. */ |
| 6533 | tail = Fmember (make_fixnum_or_float (pid), deleted_pid_list); | 6533 | for (tail = deleted_pid_list; GC_CONSP (tail); tail = XCDR (tail)) |
| 6534 | if (!NILP (tail)) | ||
| 6535 | { | 6534 | { |
| 6536 | Fsetcar (tail, Qnil); | 6535 | Lisp_Object xpid = XCAR (tail); |
| 6537 | goto sigchld_end_of_loop; | 6536 | if ((GC_INTEGERP (xpid) && pid == (pid_t) XINT (xpid)) |
| 6537 | || (GC_FLOATP (xpid) && pid == (pid_t) XFLOAT_DATA (xpid))) | ||
| 6538 | { | ||
| 6539 | XSETCAR (tail, Qnil); | ||
| 6540 | goto sigchld_end_of_loop; | ||
| 6541 | } | ||
| 6538 | } | 6542 | } |
| 6539 | 6543 | ||
| 6540 | /* Otherwise, if it is asynchronous, it is in Vprocess_alist. */ | 6544 | /* Otherwise, if it is asynchronous, it is in Vprocess_alist. */ |