]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
To reduce the endless nuisance of multiple different names for "the
authorJulian Seward <jseward@acm.org>
Wed, 18 Jan 2006 04:20:04 +0000 (04:20 +0000)
committerJulian Seward <jseward@acm.org>
Wed, 18 Jan 2006 04:20:04 +0000 (04:20 +0000)
frame below main()" screwing up the testsuite, change all known
incarnations of said into a single name, "(below main)".

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5547

coregrind/m_demangle/demangle.c
memcheck/tests/badjump.stderr.exp
memcheck/tests/badjump2.stderr.exp

index 3b4e4096d0b69fd44a575563844afee226b23f6f..a895368a2aca5cf1dfac733841622c5f27177697 100644 (file)
@@ -90,6 +90,13 @@ void VG_(demangle) ( Char* orig, Char* result, Int result_size )
    // does leak.  But, we can't do much about it, and it's not a disaster,
    // so we just let it slide without aborting or telling the user.
 
+   // Finally, to reduce the endless nuisance of multiple different names 
+   // for "the frame below main()" screwing up the testsuite, change all
+   // known incarnations of said into a single name, "(below main)".
+   if (0==VG_(strcmp)("__libc_start_main", result)
+       || 0==VG_(strcmp)("generic_start_main", result))
+      VG_(strncpy_safely)(result, "(below main)", 13);
+
 #  undef N_ZBUF
 }
 
index 74c7dde7de67ca25dd71f0e3526994b3253dbbe5..6e723e558fe561d3b3efc98a320f37834882945d 100644 (file)
@@ -1,13 +1,13 @@
 
 Jump to the invalid address stated on the next line
    at 0x........: ???
-   by 0x........: __libc_start_main (in /...libc...)
+   by 0x........: (below main) (in /...libc...)
  Address 0x........ is not stack'd, malloc'd or (recently) free'd
 
 Process terminating with default action of signal 11 (SIGSEGV)
  Access not within mapped region at address 0x........
    at 0x........: ???
-   by 0x........: __libc_start_main (in /...libc...)
+   by 0x........: (below main) (in /...libc...)
 
 ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 0 from 0)
 malloc/free: in use at exit: 0 bytes in 0 blocks.
index 741ad1e96059d87011f8ba929da6bb3a39c0ba3f..ba259959885b35b4298583aa3e6656b06b0da315 100644 (file)
@@ -1,5 +1,5 @@
 Jump to the invalid address stated on the next line
    at 0x........: ???
-   by 0x........: __libc_start_main (in /...libc...)
+   by 0x........: (below main) (in /...libc...)
  Address 0x........ is not stack'd, malloc'd or (recently) free'd
 Signal caught, as expected