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

Issue 10704002: Fix some fragile code that is likely to cause future memory corruption problems. (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
9 years, 10 months ago by erikchen
Modified:
9 years, 10 months ago
Reviewers:
Mark Mentovai
Base URL:
http://google-breakpad.googlecode.com/svn/trunk/
Visibility:
Public.

Description

Fix some fragile code that is likely to cause future memory corruption
problems.

- The ordering of keys in stl containers cannot change. Make the relevant 
members const to guarantee this assumption.
- Add handling and logging for demangle errors.
- Fix a potential double-delete bug if a function passed to AddFunction() is 
already present.

BUG=chromium:449214
R=mark@chromium.org

Patch Set 1 #

Total comments: 10

Patch Set 2 : Comments from mark@. Added missing code. #

Patch Set 3 : Fix typo in dwarf_cu_to_module_unittest.cc. #

Unified diffs Side-by-side diffs Delta from patch set Stats Patch
M src/common/dwarf_cu_to_module.cc View 1 3 chunks +21 lines, -7 lines 0 comments Download
M src/common/dwarf_cu_to_module.h View 1 1 chunk +3 lines, -0 lines 0 comments Download
M src/common/dwarf_cu_to_module_unittest.cc View 1 2 2 chunks +4 lines, -5 lines 0 comments Download
M src/common/linux/elf_symbols_to_module.cc View 1 chunk +1 line, -2 lines 0 comments Download
M src/common/module.cc View 1 3 chunks +3 lines, -6 lines 0 comments Download
M src/common/module.h View 1 4 chunks +11 lines, -4 lines 0 comments Download
M src/common/module_unittest.cc View 8 chunks +17 lines, -29 lines 0 comments Download
M src/common/stabs_to_module.cc View 3 chunks +2 lines, -5 lines 0 comments Download

Messages

Total messages: 5
erikchen
mark: Please review. I've tested compilation on Mac/Linux, and run tests via "make check" on ...
9 years, 10 months ago #1
Mark Mentovai
https://breakpad.appspot.com/10704002/diff/1/src/common/module.cc File src/common/module.cc (right): https://breakpad.appspot.com/10704002/diff/1/src/common/module.cc#newcode78 src/common/module.cc:78: void Module::AddFunction(Function *function) { The CL description said you’d ...
9 years, 10 months ago #2
erikchen
mark: PTAL https://breakpad.appspot.com/10704002/diff/1/src/common/module.cc File src/common/module.cc (right): https://breakpad.appspot.com/10704002/diff/1/src/common/module.cc#newcode78 src/common/module.cc:78: void Module::AddFunction(Function *function) { On 2015/01/27 00:11:57, ...
9 years, 10 months ago #3
Mark Mentovai
That’s better. LGTM.
9 years, 10 months ago #4
erikchen
9 years, 10 months ago #5
Message was sent while issue was closed.
Manually submitted patch set 3 as
https://code.google.com/p/google-breakpad/source/detail?r=1415
Sign in to reply to this message.

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