[llvm-commits] CVS: llvm/lib/Bytecode/Archive/ArchiveWriter.cpp
Chris Lattner
lattner at cs.uiuc.edu
Fri Jul 28 15:30:11 PDT 2006
Changes in directory llvm/lib/Bytecode/Archive:
ArchiveWriter.cpp updated: 1.24 -> 1.25
---
Log message:
Modify Path::eraseFromDisk to not throw an exception.
---
Diffs of the changes: (+5 -6)
ArchiveWriter.cpp | 11 +++++------
1 files changed, 5 insertions(+), 6 deletions(-)
Index: llvm/lib/Bytecode/Archive/ArchiveWriter.cpp
diff -u llvm/lib/Bytecode/Archive/ArchiveWriter.cpp:1.24 llvm/lib/Bytecode/Archive/ArchiveWriter.cpp:1.25
--- llvm/lib/Bytecode/Archive/ArchiveWriter.cpp:1.24 Fri Jul 28 17:03:44 2006
+++ llvm/lib/Bytecode/Archive/ArchiveWriter.cpp Fri Jul 28 17:29:50 2006
@@ -396,7 +396,7 @@
std::ofstream ArchiveFile(TmpArchive.c_str(), io_mode);
// Check for errors opening or creating archive file.
- if ( !ArchiveFile.is_open() || ArchiveFile.bad() ) {
+ if (!ArchiveFile.is_open() || ArchiveFile.bad()) {
if (TmpArchive.exists())
TmpArchive.eraseFromDisk();
if (error)
@@ -415,10 +415,9 @@
// Loop over all member files, and write them out. Note that this also
// builds the symbol table, symTab.
- for ( MembersList::iterator I = begin(), E = end(); I != E; ++I) {
- if (!writeMember(*I,ArchiveFile,CreateSymbolTable,
- TruncateNames,Compress,error))
- {
+ for (MembersList::iterator I = begin(), E = end(); I != E; ++I) {
+ if (!writeMember(*I, ArchiveFile, CreateSymbolTable,
+ TruncateNames, Compress, error)) {
if (TmpArchive.exists())
TmpArchive.eraseFromDisk();
ArchiveFile.close();
@@ -448,7 +447,7 @@
sys::RemoveFileOnSignal(FinalFilePath);
std::ofstream FinalFile(FinalFilePath.c_str(), io_mode);
- if ( !FinalFile.is_open() || FinalFile.bad() ) {
+ if (!FinalFile.is_open() || FinalFile.bad()) {
if (TmpArchive.exists())
TmpArchive.eraseFromDisk();
if (error)
More information about the llvm-commits
mailing list