diff options
Diffstat (limited to 'src/common/linux/tests')
-rw-r--r-- | src/common/linux/tests/crash_generator.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/common/linux/tests/crash_generator.cc b/src/common/linux/tests/crash_generator.cc index dd681139..36319676 100644 --- a/src/common/linux/tests/crash_generator.cc +++ b/src/common/linux/tests/crash_generator.cc @@ -184,6 +184,12 @@ bool CrashGenerator::CreateChildCrash( pid_t pid = fork(); if (pid == 0) { + // Custom signal handlers, which may have been installed by a test launcher, + // are undesirable in this child. + if (signal(crash_signal, SIG_DFL) == SIG_ERR) { + perror("CrashGenerator: signal"); + exit(1); + } if (chdir(temp_dir_.path().c_str()) == -1) { perror("CrashGenerator: Failed to change directory"); exit(1); |