diff options
| author | Wayne Davison <wayned@samba.org> | 2006-12-06 17:21:59 +0000 |
|---|---|---|
| committer | Wayne Davison <wayned@samba.org> | 2006-12-06 17:21:59 +0000 |
| commit | d365e229678eb7ae758a415d100043f6e07dea35 (patch) | |
| tree | 53bb0e33a15bbf84801844f7ec2655d5d5729c82 /main.c | |
| parent | d02363609a73a62a2c5cfd06f02a7e8babe1bc75 (diff) | |
| download | android_external_rsync-d365e229678eb7ae758a415d100043f6e07dea35.tar.gz android_external_rsync-d365e229678eb7ae758a415d100043f6e07dea35.tar.bz2 android_external_rsync-d365e229678eb7ae758a415d100043f6e07dea35.zip | |
The wait_process() call now handles EINTR.
Diffstat (limited to 'main.c')
| -rw-r--r-- | main.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -103,7 +103,11 @@ static void show_malloc_stats(void); * remember_children(), we succeed instead of returning an error. */ pid_t wait_process(pid_t pid, int *status_ptr, int flags) { - pid_t waited_pid = waitpid(pid, status_ptr, flags); + pid_t waited_pid; + + do { + waited_pid = waitpid(pid, status_ptr, flags); + } while (waited_pid == -1 && errno == EINTR); if (waited_pid == -1 && errno == ECHILD) { /* Status of requested child no longer available: check to |
