Argh! We want to return the old signal set when the error return is zero

(i.e. success), not non-zero (failure).

Submitted by:	tegge
Pointy hat to:	jhb
This commit is contained in:
John Baldwin 2003-04-28 19:43:11 +00:00
parent 4b47a81537
commit 2f7ed219b2

View File

@ -252,7 +252,7 @@ linux_do_sigprocmask(struct thread *td, int how, l_sigset_t *new,
} else
nmaskp = NULL;
error = kern_sigprocmask(td, how, nmaskp, &omask, 0);
if (error != 0 && old != NULL)
if (error == 0 && old != NULL)
bsd_to_linux_sigset(&omask, old);
return (error);