when killing gconf helper, loop over EINTR

This commit is contained in:
Lennart Poettering 2008-10-01 23:42:32 +02:00
parent ea15ca9862
commit cf3f80e8b4

View file

@ -378,7 +378,16 @@ void pa__done(pa_module*m) {
if (u->pid != (pid_t) -1) {
kill(u->pid, SIGTERM);
waitpid(u->pid, NULL, 0);
for (;;) {
if (waitpid(u->pid, NULL, 0) >= 0)
break;
if (errno != EINTR) {
pa_log("waitpid() failed: %s", pa_cstrerror(errno));
break;
}
}
}
if (u->io_event)
@ -387,7 +396,6 @@ void pa__done(pa_module*m) {
if (u->fd >= 0)
pa_close(u->fd);
if (u->module_infos)
pa_hashmap_free(u->module_infos, module_info_free, u);