diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2012-01-07 03:13:18 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2012-01-07 03:13:18 +0000 |
commit | 99b4237c1647156f0e1d3d7e03efdab23ed79778 (patch) | |
tree | d42c2ee376e2ae4534420e024205edc6b7cca8fe /lib/MC/MCELFStreamer.cpp | |
parent | 977679d6034791fd48a344e5b990503ba50fc242 (diff) | |
download | llvm-99b4237c1647156f0e1d3d7e03efdab23ed79778.tar.gz llvm-99b4237c1647156f0e1d3d7e03efdab23ed79778.tar.bz2 llvm-99b4237c1647156f0e1d3d7e03efdab23ed79778.tar.xz |
Split Finish into Finish and FinishImpl to have a common place to do end of
file error checking. Use that to error on an unfinished cfi_startproc.
The error is not nice, but is already better than a segmentation fault.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@147717 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/MC/MCELFStreamer.cpp')
-rw-r--r-- | lib/MC/MCELFStreamer.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/MC/MCELFStreamer.cpp b/lib/MC/MCELFStreamer.cpp index dcc4666a26..aaae21f68b 100644 --- a/lib/MC/MCELFStreamer.cpp +++ b/lib/MC/MCELFStreamer.cpp @@ -356,7 +356,7 @@ void MCELFStreamer::EmitInstToData(const MCInst &Inst) { DF->getContents().append(Code.begin(), Code.end()); } -void MCELFStreamer::Finish() { +void MCELFStreamer::FinishImpl() { EmitFrames(true); for (std::vector<LocalCommon>::const_iterator i = LocalCommons.begin(), @@ -379,7 +379,7 @@ void MCELFStreamer::Finish() { SectData.setAlignment(ByteAlignment); } - this->MCObjectStreamer::Finish(); + this->MCObjectStreamer::FinishImpl(); } MCStreamer *llvm::createELFStreamer(MCContext &Context, MCAsmBackend &MAB, |