diff options
author | SiyangXie@gmail.com <SiyangXie@gmail.com@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2010-10-07 20:31:36 +0000 |
---|---|---|
committer | SiyangXie@gmail.com <SiyangXie@gmail.com@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2010-10-07 20:31:36 +0000 |
commit | 5b117cf53af46f357d28761ced3a1d94aeb5df91 (patch) | |
tree | 2d6a68637909ef385a5fef6e21962f749d6ef9eb /src/processor/stackwalker_arm_unittest.cc | |
parent | Make dump_syms output an INFO CODE_ID line that includes the code file and co... (diff) | |
download | breakpad-5b117cf53af46f357d28761ced3a1d94aeb5df91.tar.xz |
Refactor source line resolver, add interface in supplier and resolver.
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@711 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src/processor/stackwalker_arm_unittest.cc')
-rw-r--r-- | src/processor/stackwalker_arm_unittest.cc | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/processor/stackwalker_arm_unittest.cc b/src/processor/stackwalker_arm_unittest.cc index ad7aeb31..637435b1 100644 --- a/src/processor/stackwalker_arm_unittest.cc +++ b/src/processor/stackwalker_arm_unittest.cc @@ -87,15 +87,18 @@ class StackwalkerARMFixture { // By default, none of the modules have symbol info; call // SetModuleSymbols to override this. - EXPECT_CALL(supplier, GetSymbolFile(_, _, _, _)) + EXPECT_CALL(supplier, GetCStringSymbolData(_, _, _, _)) .WillRepeatedly(Return(MockSymbolSupplier::NOT_FOUND)); } // Set the Breakpad symbol information that supplier should return for // MODULE to INFO. void SetModuleSymbols(MockCodeModule *module, const string &info) { - EXPECT_CALL(supplier, GetSymbolFile(module, &system_info, _, _)) - .WillRepeatedly(DoAll(SetArgumentPointee<3>(info), + unsigned int buffer_size = info.size() + 1; + char *buffer = reinterpret_cast<char*>(operator new(buffer_size)); + strcpy(buffer, info.c_str()); + EXPECT_CALL(supplier, GetCStringSymbolData(module, &system_info, _, _)) + .WillRepeatedly(DoAll(SetArgumentPointee<3>(buffer), Return(MockSymbolSupplier::FOUND))); } |