mirror of
https://git.suyu.dev/suyu/breakpad.git
synced 2025-12-26 17:25:04 +01:00
Server-side workaround to handle overlapping modules.
This change is resolving an issue that was caused by the combination of: - Android system libraries being relro packed in N+. - Breakpad dealing with relro packed libraries in a hack way. This is a fix for http://crbug/611824. I also found an use-after-free issue (bug in Minidump::SeekToStreamType). I disallowed the MinidumpStreamInfo copy and assign constructors and the compiler detected another similar issue in Minidump::Print. Then I disabled the copy and assign constructors for most classes in minidump.h (just in case). There are a couple of classes where I couldn't disallow them (since assign is used). This will require a small refactor so I left it out of this CL. R=mark@chromium.org Review URL: https://codereview.chromium.org/2060663002 .
This commit is contained in:
parent
67f738b7ad
commit
24f5931c5e
18 changed files with 239 additions and 39 deletions
|
|
@ -43,6 +43,8 @@
|
|||
|
||||
#include <stddef.h>
|
||||
|
||||
#include <vector>
|
||||
|
||||
#include "google_breakpad/processor/code_modules.h"
|
||||
#include "processor/linked_ptr.h"
|
||||
#include "processor/range_map.h"
|
||||
|
|
@ -67,6 +69,9 @@ class BasicCodeModules : public CodeModules {
|
|||
virtual const CodeModule* GetModuleAtSequence(unsigned int sequence) const;
|
||||
virtual const CodeModule* GetModuleAtIndex(unsigned int index) const;
|
||||
virtual const CodeModules* Copy() const;
|
||||
virtual std::vector<linked_ptr<const CodeModule> >
|
||||
GetShrunkRangeModules() const;
|
||||
virtual bool IsModuleShrinkEnabled() const;
|
||||
|
||||
protected:
|
||||
BasicCodeModules();
|
||||
|
|
@ -78,6 +83,10 @@ class BasicCodeModules : public CodeModules {
|
|||
// address range.
|
||||
RangeMap<uint64_t, linked_ptr<const CodeModule> > map_;
|
||||
|
||||
// A vector of all CodeModules that were shrunk downs due to
|
||||
// address range conflicts.
|
||||
std::vector<linked_ptr<const CodeModule> > shrunk_range_modules_;
|
||||
|
||||
private:
|
||||
// Disallow copy constructor and assignment operator.
|
||||
BasicCodeModules(const BasicCodeModules &that);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue