summaryrefslogtreecommitdiff
path: root/include/llvm/MC/MCSection.h
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2010-03-15 06:23:52 +0000
committerChris Lattner <sabre@nondot.org>2010-03-15 06:23:52 +0000
commit1f8008cf214b984954de2e986fb8cb0e5cc58606 (patch)
treefcb0837c9a3e2e4a69bb24cf6e92a0e6a9b63ab2 /include/llvm/MC/MCSection.h
parentc28cc093e3b5b8601cb5024a5365a6f31f49839a (diff)
downloadllvm-1f8008cf214b984954de2e986fb8cb0e5cc58606.tar.gz
llvm-1f8008cf214b984954de2e986fb8cb0e5cc58606.tar.bz2
llvm-1f8008cf214b984954de2e986fb8cb0e5cc58606.tar.xz
fix MCSectionELF to not leak memory, just like I did for MCSymbol.
MCSectionMachO is already fine (yay for fixed size arrays?), MCSectionCOFF still leaks. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@98537 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/MC/MCSection.h')
-rw-r--r--include/llvm/MC/MCSection.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/llvm/MC/MCSection.h b/include/llvm/MC/MCSection.h
index ceb6d278c9..3d8815a778 100644
--- a/include/llvm/MC/MCSection.h
+++ b/include/llvm/MC/MCSection.h
@@ -42,6 +42,8 @@ namespace llvm {
};
class MCSectionCOFF : public MCSection {
+ // FIXME: This memory is leaked because MCSectionCOFF is bump pointer
+ // allocated and this never gets freed.
std::string Name;
/// IsDirective - This is true if the section name is a directive, not