mirror of
https://sourceware.org/git/glibc.git
synced 2025-12-24 17:51:17 +03:00
linux: Do not reset signal handler in posix_spawn if it is already SIG_DFL
There is no need to issue another sigaction if the disposition is already SIG_DFL. Checked on x86_64-linux-gnu. Reviewed-by: Carlos O'Donell <carlos@redhat.com>
This commit is contained in:
committed by
Adhemerval Zanella
parent
2412deae1a
commit
ff9ffc805f
@@ -129,7 +129,7 @@ __spawni_child (void *arguments)
|
||||
else
|
||||
{
|
||||
__libc_sigaction (sig, 0, &sa);
|
||||
if (sa.sa_handler == SIG_IGN)
|
||||
if (sa.sa_handler == SIG_IGN || sa.sa_handler == SIG_DFL)
|
||||
continue;
|
||||
sa.sa_handler = SIG_DFL;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user