projects
/
sudo
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9f461ef
)
Add missing initialization of a sigaction structure when I/O logging.
author
Todd C. Miller
<Todd.Miller@courtesan.com>
Mon, 23 Apr 2012 18:56:31 +0000
(14:56 -0400)
committer
Todd C. Miller
<Todd.Miller@courtesan.com>
Mon, 23 Apr 2012 18:56:31 +0000
(14:56 -0400)
Fixes a potential problem when suspending the command.
src/exec_pty.c
patch
|
blob
|
history
diff --git
a/src/exec_pty.c
b/src/exec_pty.c
index ba77b014c4f4f3fe247798b442057b76668d2d5f..0011847909551709923d558200f04a617f4cfec7 100644
(file)
--- a/
src/exec_pty.c
+++ b/
src/exec_pty.c
@@
-334,6
+334,9
@@
suspend_parent(int signo)
}
/* Suspend self and continue child when we resume. */
+ zero_bytes(&sa, sizeof(sa));
+ sigemptyset(&sa.sa_mask);
+ sa.sa_flags = SA_INTERRUPT; /* do not restart syscalls */
sa.sa_handler = SIG_DFL;
sigaction(signo, &sa, &osa);
sudo_debug_printf(SUDO_DEBUG_INFO, "kill parent %d", signo);