diff options
author | Ed Maste <emaste@freebsd.org> | 2014-02-16 04:01:54 +0000 |
---|---|---|
committer | Ed Maste <emaste@freebsd.org> | 2014-02-16 04:01:54 +0000 |
commit | ff8e5f2587145bdd2f4194ab0472889933ee4fb0 (patch) | |
tree | 625ff69c54c475f2ff7516c37113a02f07914e76 /llvm/lib/MC/MCParser/AsmParser.cpp | |
parent | 53d8b200784b289c859efd40681038da4c11a777 (diff) | |
download | bcm5719-llvm-ff8e5f2587145bdd2f4194ab0472889933ee4fb0.tar.gz bcm5719-llvm-ff8e5f2587145bdd2f4194ab0472889933ee4fb0.zip |
elf-core: Plug latent memory leak
ProcessElfCore::ParseThreadContextsFromNoteSegment was leaking
ThreadData for each ELF note found in core file. We now allocate it
only once and use std::unique_ptr to ensure it is always being freed.
While at it make ParseFreeBSDThrMisc and ParseFreeBSDPrStatus take
ThreadData by reference, rather than pointer, since those arguments are
not optional.
Patch by Piotr Rak.
http://llvm-reviews.chandlerc.com/D2813
llvm-svn: 201473
Diffstat (limited to 'llvm/lib/MC/MCParser/AsmParser.cpp')
0 files changed, 0 insertions, 0 deletions