1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 11:13:28 +01:00

llvm-mc: Delete output files on error.

llvm-svn: 98445
This commit is contained in:
Daniel Dunbar 2010-03-13 19:31:47 +00:00
parent 6d5fa0c9d6
commit 661d89861c

View File

@ -311,6 +311,10 @@ static int AssembleInput(const char *ProgName) {
if (Out != &fouts())
delete Out;
// Delete output on errors.
if (Res && OutputFilename != "-")
sys::Path(OutputFilename).eraseFromDisk();
return Res;
}