diff options
author | nealsid <nealsid@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2009-05-14 21:31:03 +0000 |
---|---|---|
committer | nealsid <nealsid@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2009-05-14 21:31:03 +0000 |
commit | fc26f4a9b5487306b311bb9c5b04e27e2f4e3280 (patch) | |
tree | f1f669550b6f75de6381add075b8e09e6952f93e /src/processor | |
parent | Deleting obsolete file(when I added DWARF support I had to make this a .MM bu... (diff) | |
download | breakpad-fc26f4a9b5487306b311bb9c5b04e27e2f4e3280.tar.xz |
Fix memory leak in test case when calling into basic source line resolver.
R=brdevmn
A=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@338 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src/processor')
-rw-r--r-- | src/processor/basic_source_line_resolver_unittest.cc | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/processor/basic_source_line_resolver_unittest.cc b/src/processor/basic_source_line_resolver_unittest.cc index 95595a85..cea98b84 100644 --- a/src/processor/basic_source_line_resolver_unittest.cc +++ b/src/processor/basic_source_line_resolver_unittest.cc @@ -173,8 +173,10 @@ static bool RunTests() { ASSERT_EQ(frame_info->prolog_size, 1); frame.instruction = 0x216f; - resolver.FillSourceLineInfo(&frame); + StackFrameInfo *s; + s = resolver.FillSourceLineInfo(&frame); ASSERT_EQ(frame.function_name, "Public2_1"); + delete s; ClearSourceLineInfo(&frame); frame.instruction = 0x219f; @@ -184,9 +186,11 @@ static bool RunTests() { frame.instruction = 0x21a0; frame.module = &module2; - resolver.FillSourceLineInfo(&frame); + s = resolver.FillSourceLineInfo(&frame); ASSERT_EQ(frame.function_name, "Public2_2"); + delete s; + ASSERT_FALSE(resolver.LoadModule("module3", testdata_dir + "/module3_bad.out")); ASSERT_FALSE(resolver.HasModule("module3")); |