]> sourceware.org Git - systemtap.git/commitdiff
stap_run.exp: accept 'WARNING: Child process exited due to signal'
authorSerguei Makarov <smakarov@redhat.com>
Thu, 14 Oct 2021 20:44:23 +0000 (16:44 -0400)
committerSerguei Makarov <smakarov@redhat.com>
Thu, 14 Oct 2021 20:53:42 +0000 (16:53 -0400)
This was causing numerous spurious FAIL outcomes on RHEL[89].
The extra "WARNING: Child process exited due to signal" is not an error,
it's merely stap communicating to the user that the child
process was interrupted, which is exactly what we do.

Not sure why it's printed on some systems and not others.
XXX There may be a deeper issue in that the tiny do-nothing binary
probed by the testcase (e.g. testsuite/systemtap.base/at_register.c)
was supposed to stop on its own and didn't.
Adding a delay to the first kill -INT $mypid makes the problem
more obvious.

testsuite/lib/stap_run.exp

index 79e8383ffbf03bd7d44a17fa0cc9ef9e0a45ea35..780994c021a7106d58afcb8f5b8f2a77fb64afcf 100644 (file)
@@ -30,6 +30,7 @@ proc stap_run { TEST_NAME {LOAD_GEN_FUNCTION ""} {OUTPUT_CHECK_STRING ""} args }
     set probe_errors 0
     set skipped_probes 0
     set warning_regexp {^WARNING: Number of errors: ([0-9]+), skipped probes: ([0-9]+)\r\n}
+    set warning_child_regexp {^WARNING: Child process exited with signal [0-9]+ \(.*\)\r\n}
 
     if {[info procs installtest_p] != "" && ![installtest_p]} { untested $TEST_NAME; return }
 
@@ -82,6 +83,8 @@ proc stap_run { TEST_NAME {LOAD_GEN_FUNCTION ""} {OUTPUT_CHECK_STRING ""} args }
                     set probe_errors $expect_out(1,string)
                     set skipped_probes $expect_out(2,string)
                     exp_continue}
+               -re  $warning_child_regexp {
+                    exp_continue}
                -re  $output {
                    pass "$TEST_NAME shutdown and output"
                    expect {
This page took 0.028628 seconds and 5 git commands to generate.