mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-10 08:16:15 +02:00
* Pid::kill() should be interruptable.
This commit is contained in:
parent
7951c3c546
commit
363f40022f
1 changed files with 3 additions and 1 deletions
|
@ -685,9 +685,11 @@ void Pid::kill()
|
|||
|
||||
/* Wait until the child dies, disregarding the exit status. */
|
||||
int status;
|
||||
while (waitpid(pid, &status, 0) == -1)
|
||||
while (waitpid(pid, &status, 0) == -1) {
|
||||
checkInterrupt();
|
||||
if (errno != EINTR) printMsg(lvlError,
|
||||
(SysError(format("waiting for process %1%") % pid).msg()));
|
||||
}
|
||||
|
||||
pid = -1;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue