Error when using minidump_stackwalk on program with recursion call

40 views
Skip to first unread message

Dexter niXman

unread,
Feb 20, 2013, 8:19:54 AM2/20/13
to google-brea...@googlegroups.com
Hi,

My code example:

#include "client/linux/handler/exception_handler.h"

static bool dumpCallback(const google_breakpad::MinidumpDescriptor& descriptor,
                         void* context,
                         bool succeeded)
{
  printf("Dump path: %s\n", descriptor.path());
  return succeeded;
}

int func(int i) {
char buf[128];
sprintf(buf, "%d", i);
func(i+1);
return buf[0];
}

void crash()
{
  //func(0); // <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
  volatile int* a = (int*)(NULL);
  *a = 1;
}

void bar() { crash(); }

void foo() { bar(); }

int main(int argc, char* argv[])
{
  google_breakpad::MinidumpDescriptor descriptor("/home/nixman");
  google_breakpad::ExceptionHandler eh(descriptor,
                                       NULL,
                                       dumpCallback,
                                       NULL,
                                       true,
                                       -1);
  foo();
  return 0;
}



If pointed string is commented - all works fine and I can view callstack using minidump_stackwalk tool successfully.
But, if I will uncomment pointed string and try to exec 'minidump_stackwalk mycore.dmp ./symbols' cmd I get the following errors:

^ 2013-02-20 17:03:12: minidump.cc:1376: ERROR: MinidumpThread has a memory region problem, 0x7fff9269bf90+0x0
  2013-02-20 17:03:12: minidump_processor.cc:128: INFO: Minidump mycore.dmp has CPU info, OS info, no Breakpad info, exception, module list, thread list, no dump thread, and requesting thread
  2013-02-20 17:03:12: minidump_processor.cc:166: INFO: Looking at thread mycore.dmp:0/1 id 0x6ae0
  2013-02-20 17:03:12: minidump.cc:309: INFO: MinidumpContext: looks like AMD64 context
^ 2013-02-20 17:03:12: minidump.cc:309: INFO: MinidumpContext: looks like AMD64 context
  2013-02-20 17:03:12: minidump_processor.cc:210: ERROR: No memory region for mycore.dmp:0/1 id 0x6ae0
  2013-02-20 17:03:12: simple_symbol_supplier.cc:193: INFO: No symbol file at ./symbols/libc-2.15.so/CCAF9582CCF7E6412934766D96223FE70/libc-2.15.so.sym
^ 2013-02-20 17:03:12: stackwalker_amd64.cc:201: ERROR: Can't get caller frame without memory or stack
  2013-02-20 17:03:12: minidump_processor.cc:275: INFO: Processed mycore.dmp
  2013-02-20 17:03:12: minidump.cc:3805: INFO: Minidump closing minidump


What i'am doing wrongly?

Thanks.

Reply all
Reply to author
Forward
0 new messages