// build the (long) command line for executing addr2line in an optimized way
// (e.g. use always chars, even in Unicode build: popen() always takes chars)
- int len = snprintf(g_buf, BUFSIZE, "addr2line -C -f -e \"%s\"", exepath.mb_str());
+ int len = snprintf(g_buf, BUFSIZE, "addr2line -C -f -e \"%s\"", (const char*) exepath.mb_str());
len = (len <= 0) ? strlen(g_buf) : len; // in case snprintf() is broken
for (size_t i=0; i<n; i++)
{
}
}
- if (!name.empty() || !filename.empty())
- {
- // now we've got enough info to initialize curr-th stack frame:
- arr[curr++].Set(name, filename, syminfo[i], i, line, addresses[i]);
- }
+ // now we've got enough info to initialize curr-th stack frame
+ // (at worst, only addresses[i] and syminfo[i] have been initialized,
+ // but wxStackFrame::OnGetName may still be able to get function name):
+ arr[curr++].Set(name, filename, syminfo[i], i, line, addresses[i]);
}
return curr;