Avoid recursion in VG_(exit).

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10285
This commit is contained in:
Nicholas Nethercote 2009-06-09 22:46:32 +00:00
parent a01f086879
commit 17ae73a356

View File

@ -107,7 +107,10 @@ void VG_(exit)( Int status )
# error Unknown OS
#endif
/*NOTREACHED*/
VG_(core_panic)("VG_(exit) didn't work?");
// We really shouldn't reach here. Just in case we do, use some very crude
// methods to force abort
__builtin_trap();
*(volatile Int*)0 = 'x';
}
// Print the scheduler status.