Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(616)

Unified Diff: src/processor/minidump_processor.cc

Issue 413002: Allow processing dumps with missing stack memory for some threads (Closed)
Patch Set: Updated patch Created 11 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/processor/minidump.cc ('k') | src/processor/minidump_processor_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/processor/minidump_processor.cc
===================================================================
--- a/src/processor/minidump_processor.cc
+++ b/src/processor/minidump_processor.cc
@@ -203,43 +203,45 @@ ProcessResult MinidumpProcessor::Process
MinidumpContext *ctx = exception->GetContext();
context = ctx ? ctx : thread->GetContext();
}
}
MinidumpMemoryRegion *thread_memory = thread->GetMemory();
if (!thread_memory) {
BPLOG(ERROR) << "No memory region for " << thread_string;
- return PROCESS_ERROR_NO_MEMORY_FOR_THREAD;
}
// Use process_state->modules_ instead of module_list, because the
// |modules| argument will be used to populate the |module| fields in
// the returned StackFrame objects, which will be placed into the
// returned ProcessState object. module_list's lifetime is only as
// long as the Minidump object: it will be deleted when this function
// returns. process_state->modules_ is owned by the ProcessState object
// (just like the StackFrame objects), and is much more suitable for this
// task.
scoped_ptr<Stackwalker> stackwalker(
Stackwalker::StackwalkerForCPU(process_state->system_info(),
context,
thread_memory,
process_state->modules_,
frame_symbolizer_));
- if (!stackwalker.get()) {
- BPLOG(ERROR) << "No stackwalker for " << thread_string;
- return PROCESS_ERROR_NO_STACKWALKER_FOR_THREAD;
- }
scoped_ptr<CallStack> stack(new CallStack());
- if (!stackwalker->Walk(stack.get())) {
- BPLOG(INFO) << "Stackwalker interrupt (missing symbols?) at " <<
+ if (stackwalker.get()) {
+ if (!stackwalker->Walk(stack.get())) {
+ BPLOG(INFO) << "Stackwalker interrupt (missing symbols?) at " <<
thread_string;
- interrupted = true;
+ interrupted = true;
+ }
+ } else {
+ // Threads with missing CPU contexts will hit this, but
+ // don't abort processing the rest of the dump just for
+ // one bad thread.
+ BPLOG(ERROR) << "No stackwalker for " << thread_string;
}
process_state->threads_.push_back(stack.release());
process_state->thread_memory_regions_.push_back(thread_memory);
}
if (interrupted) {
BPLOG(INFO) << "Processing interrupted for " << dump->path();
return PROCESS_SYMBOL_SUPPLIER_INTERRUPTED;
« no previous file with comments | « src/processor/minidump.cc ('k') | src/processor/minidump_processor_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld 1004:630ec63f810e-tainted