diff --git a/debuggerd/debuggerd_test.cpp b/debuggerd/debuggerd_test.cpp index 2cf5b18df..0737612e0 100644 --- a/debuggerd/debuggerd_test.cpp +++ b/debuggerd/debuggerd_test.cpp @@ -88,7 +88,7 @@ constexpr char kWaitForDebuggerKey[] = "debug.debuggerd.wait_for_debugger"; struct sigaction old_sigaction; \ struct sigaction new_sigaction = {}; \ new_sigaction.sa_handler = [](int) {}; \ - if (sigaction(SIGALRM, &new_sigaction, &new_sigaction) != 0) { \ + if (sigaction(SIGALRM, &new_sigaction, &old_sigaction) != 0) { \ err(1, "sigaction failed"); \ } \ alarm(seconds); \