Mercurial > emacs
comparison src/process.c @ 76456:720d443bce01
(sigchld_handler): Sleep before wait3 to avoid a busyloop.
author | Sam Steingold <sds@gnu.org> |
---|---|
date | Sun, 11 Mar 2007 18:16:50 +0000 |
parents | 9e2414dc2556 |
children | deede4f7067d |
comparison
equal
deleted
inserted
replaced
76455:dac34bd10d88 | 76456:720d443bce01 |
---|---|
6495 #define WUNTRACED 0 | 6495 #define WUNTRACED 0 |
6496 #endif /* no WUNTRACED */ | 6496 #endif /* no WUNTRACED */ |
6497 /* Keep trying to get a status until we get a definitive result. */ | 6497 /* Keep trying to get a status until we get a definitive result. */ |
6498 do | 6498 do |
6499 { | 6499 { |
6500 sleep (1); | |
6500 errno = 0; | 6501 errno = 0; |
6501 pid = wait3 (&w, WNOHANG | WUNTRACED, 0); | 6502 pid = wait3 (&w, WNOHANG | WUNTRACED, 0); |
6502 } | 6503 } |
6503 while (pid < 0 && errno == EINTR); | 6504 while (pid < 0 && errno == EINTR); |
6504 | 6505 |