Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1851)

Unified Diff: snapshot/win/module_snapshot_win.cc

Issue 1430773003: win: Handle binary with embedded CodeView debug record (Closed) Base URL: https://chromium.googlesource.com/crashpad/crashpad@master
Patch Set: rebase Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « snapshot/win/end_to_end_test.py ('k') | snapshot/win/pe_image_reader.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: snapshot/win/module_snapshot_win.cc
diff --git a/snapshot/win/module_snapshot_win.cc b/snapshot/win/module_snapshot_win.cc
index 3876fb1ed644fee124fe1726deb7127c185d79a1..194d15ac8ae915e9ce76b80038f5ff9d079d82f4 100644
--- a/snapshot/win/module_snapshot_win.cc
+++ b/snapshot/win/module_snapshot_win.cc
@@ -60,6 +60,14 @@ bool ModuleSnapshotWin::Initialize(
&uuid_, &age_dword, &pdb_name_)) {
static_assert(sizeof(DWORD) == sizeof(uint32_t), "unexpected age size");
age_ = age_dword;
+ } else {
+ // If we fully supported all old debugging formats, we would want to extract
+ // and emit a different type of CodeView record here (as old Microsoft tools
+ // would do). As we don't expect to ever encounter a module that wouldn't be
+ // be using .PDB that we actually have symbols for, we simply set a
+ // plausible name here, but this will never correspond to symbols that we
+ // have.
+ pdb_name_ = base::UTF16ToUTF8(name_);
}
INITIALIZATION_STATE_SET_VALID(initialized_);
« no previous file with comments | « snapshot/win/end_to_end_test.py ('k') | snapshot/win/pe_image_reader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698