]> git.ipfire.org Git - thirdparty/elfutils.git/commitdiff
Fix false FAILs on testsuite with ulimit -c unlimited.
authorJan Kratochvil <jan.kratochvil@redhat.com>
Sat, 18 Jan 2014 20:56:13 +0000 (21:56 +0100)
committerJan Kratochvil <jan.kratochvil@redhat.com>
Sat, 18 Jan 2014 20:56:13 +0000 (21:56 +0100)
Signed-off-by: Jan Kratochvil <jan.kratochvil@redhat.com>
tests/ChangeLog
tests/backtrace-child.c

index 1b84f3a18b72f7863455ffaa154226eef4f02cb0..df5c509ae85881fa5d02049a23243c16d060dcd4 100644 (file)
@@ -1,3 +1,9 @@
+2014-01-18  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+       Fix false FAILs on testsuite with ulimit -c unlimited.
+       * backtrace-child.c (sigusr2): Call pthread_exit.
+       (main): Return, do not call abort.
+
 2014-01-15  Jan Kratochvil  <jan.kratochvil@redhat.com>
 
        Fix corruption of non-C++ symbols by the demangler.
index 0db125899893beb22d98723853aa070a31b48cbb..512aa2382c9ca7192baf0ff832dcc584b831118d 100644 (file)
@@ -100,7 +100,10 @@ sigusr2 (int signo)
   if (! gencore)
     {
       raise (SIGUSR1);
-      /* It should not be reached.  */
+      /* Do not return as stack may be invalid due to ptrace-patched PC to the
+        jmp function.  */
+      pthread_exit (NULL);
+      /* Not reached.  */
       abort ();
     }
   /* Here we dump the core for --gencore.  */
@@ -218,6 +221,5 @@ main (int argc UNUSED, char **argv)
     pthread_join (thread, NULL);
   else
     raise (SIGUSR2);
-  /* Not reached.  */
-  abort ();
+  return 0;
 }