Changes in directory llvm/lib/System/Unix:
MappedFile.inc updated: 1.14 -> 1.15 --- Log message: Remove a dead conditional: info_ can only be allocated if FD is good. Improve spacing --- Diffs of the changes: (+4 -5) MappedFile.inc | 9 ++++----- 1 files changed, 4 insertions(+), 5 deletions(-) Index: llvm/lib/System/Unix/MappedFile.inc diff -u llvm/lib/System/Unix/MappedFile.inc:1.14 llvm/lib/System/Unix/MappedFile.inc:1.15 --- llvm/lib/System/Unix/MappedFile.inc:1.14 Tue Jul 18 02:01:08 2006 +++ llvm/lib/System/Unix/MappedFile.inc Tue Jul 18 02:03:14 2006 @@ -44,12 +44,12 @@ throw std::string("Can't open file: ") + path_.toString(); int mode = 0; - if (options_&READ_ACCESS) - if (options_&WRITE_ACCESS) + if (options_ & READ_ACCESS) + if (options_ & WRITE_ACCESS) mode = O_RDWR; else mode = O_RDONLY; - else if (options_&WRITE_ACCESS) + else if (options_ & WRITE_ACCESS) mode = O_WRONLY; int FD = ::open(path_.c_str(), mode); @@ -68,8 +68,7 @@ void MappedFile::terminate() { assert(info_ && "MappedFile not initialized"); - if (info_->FD >= 0) - ::close(info_->FD); + ::close(info_->FD); delete info_; info_ = 0; } _______________________________________________ llvm-commits mailing list llvm-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits