aboutsummaryrefslogtreecommitdiff
path: root/src/common/windows/pdb_source_line_writer.h
diff options
context:
space:
mode:
authormmentovai <mmentovai@4c0a9323-5329-0410-9bdc-e9ce6186880e>2006-12-06 20:18:26 +0000
committermmentovai <mmentovai@4c0a9323-5329-0410-9bdc-e9ce6186880e>2006-12-06 20:18:26 +0000
commit93fa375b580a647904925cb741266f2d679cb448 (patch)
tree2de0c843bdbce248393012eeecbe7e23572547da /src/common/windows/pdb_source_line_writer.h
parentFix possible null pointer dereference in MinidumpModule (following #32). (diff)
downloadbreakpad-93fa375b580a647904925cb741266f2d679cb448.tar.xz
symupload parameters don't match processor expectations (#91). r=bryner
- Interface change: the "guid" and "age" parameters supplied to a symbol server by symupload have been merged into "debug_identifier". Some other parameters have had their names changed. Additional code_file, os, and cpu parameters have been added. - Interface change: the format of the MODULE line at the top of dumped .sym files has changed slightly. The fields used for uuid and age have merged into a debug_identifier-type field. - debug_identifier is formatted the same way as CodeModule::debug_identifier for ease of server-side processing. http://groups.google.com/group/airbag-dev/browse_thread/thread/8022f504cf01f994 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@77 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src/common/windows/pdb_source_line_writer.h')
-rw-r--r--src/common/windows/pdb_source_line_writer.h35
1 files changed, 23 insertions, 12 deletions
diff --git a/src/common/windows/pdb_source_line_writer.h b/src/common/windows/pdb_source_line_writer.h
index b4db5bc7..a2818263 100644
--- a/src/common/windows/pdb_source_line_writer.h
+++ b/src/common/windows/pdb_source_line_writer.h
@@ -45,6 +45,26 @@ namespace google_airbag {
using std::wstring;
+// A structure that carries information that identifies a pdb file.
+struct PDBModuleInfo {
+ public:
+ // The basename of the pdb file from which information was loaded.
+ wstring debug_file;
+
+ // The pdb's identifier. For recent pdb files, the identifier consists
+ // of the pdb's guid, in uppercase hexadecimal form without any dashes
+ // or separators, followed immediately by the pdb's age, also in
+ // uppercase hexadecimal form. For older pdb files which have no guid,
+ // the identifier is the pdb's 32-bit signature value, in zero-padded
+ // hexadecimal form, followed immediately by the pdb's age, in lowercase
+ // hexadecimal form.
+ wstring debug_identifier;
+
+ // A string identifying the cpu that the pdb is associated with.
+ // Currently, this may be "x86" or "unknown".
+ wstring cpu;
+};
+
class PDBSourceLineWriter {
public:
enum FileFormat {
@@ -74,15 +94,9 @@ class PDBSourceLineWriter {
// Closes the current pdb file and its associated resources.
void Close();
- // Sets guid to the GUID for the module, as a string,
- // e.g. "11111111-2222-3333-4444-555555555555". If the module has no guid,
- // guid will instead be set to the module's 32-bit signature value, in
- // zero-padded hexadecimal form, such as "0004beef". age will be set to the
- // age of the pdb file, filename will be set to the basename of the pdb's
- // file name, and cpu will be set to a string identifying the associated CPU
- // architecture. cpu is permitted to be NULL, in which case CPU information
- // will not be returned. Returns true on success and false on failure.
- bool GetModuleInfo(wstring *guid, int *age, wstring *filename, wstring *cpu);
+ // Retrieves information about the module's debugging file. Returns
+ // true on success and false on failure.
+ bool GetModuleInfo(PDBModuleInfo *info);
// Sets uses_guid to true if the opened file uses a new-style CodeView
// record with a 128-bit GUID, or false if the opened file uses an old-style
@@ -120,9 +134,6 @@ class PDBSourceLineWriter {
// its uuid and age.
bool PrintPDBInfo();
- // Returns the base name of a file, e.g. strips off the path.
- static wstring GetBaseName(const wstring &filename);
-
// Returns the function name for a symbol. If possible, the name is
// undecorated. If the symbol's decorated form indicates the size of
// parameters on the stack, this information is returned in stack_param_size.