Change nsTraceRefcnt::WalkTheStack() to accept stream.

git-svn-id: svn://10.0.0.236/trunk@51353 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
waterson%netscape.com
1999-10-21 03:45:12 +00:00
parent 21abead461
commit 035b04b87b
2 changed files with 4 additions and 44 deletions

View File

@@ -648,28 +648,8 @@ ah_crap_handler(int signum)
getpid(),
strsignal(signum));
char stack[4096];
nsTraceRefcnt::WalkTheStack(stack, sizeof(stack));
// Convert all spaces between symbols to newlines for readability
char * needle = "+0x";
char * haystack = stack;
char * sp = NULL;
while((sp = strstr(haystack,needle)))
{
char * ws = strchr(sp,' ');
if (ws)
{
*ws = '\n';
haystack = ws + 1;
}
}
printf("stack = %s\n\n",stack);
printf("stack\n",stack);
nsTraceRefcnt::WalkTheStack(stdout);
printf("Sleeping for 5 minutes.\n");
printf("Type 'gdb %s %d' to attatch your debugger to this thread.\n",