diff options
author | Chris Lattner <sabre@nondot.org> | 2006-07-28 22:36:17 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2006-07-28 22:36:17 +0000 |
commit | 60c5064538bea30bda9907e395a90a74b9a4098b (patch) | |
tree | 4af305cc40fccde5a80868a3f92a1ba82c6d4278 /llvm/lib/System/Unix | |
parent | 60fbecabf82abde96397ab9c5206bb4da4c6d01d (diff) | |
download | bcm5719-llvm-60c5064538bea30bda9907e395a90a74b9a4098b.tar.gz bcm5719-llvm-60c5064538bea30bda9907e395a90a74b9a4098b.zip |
Modify setStatusInfoOnDisk to not throw an exception.
llvm-svn: 29402
Diffstat (limited to 'llvm/lib/System/Unix')
-rw-r--r-- | llvm/lib/System/Unix/Path.inc | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/System/Unix/Path.inc b/llvm/lib/System/Unix/Path.inc index 26f29c0bc0c..f26315cea62 100644 --- a/llvm/lib/System/Unix/Path.inc +++ b/llvm/lib/System/Unix/Path.inc @@ -647,15 +647,15 @@ Path::renamePathOnDisk(const Path& newName) { } bool -Path::setStatusInfoOnDisk(const FileStatus &si) const { +Path::setStatusInfoOnDisk(const FileStatus &si, std::string *ErrStr) const { struct utimbuf utb; utb.actime = si.modTime.toPosixTime(); utb.modtime = utb.actime; if (0 != ::utime(path.c_str(),&utb)) - ThrowErrno(path + ": can't set file modification time"); + return GetErrno(path + ": can't set file modification time", ErrStr); if (0 != ::chmod(path.c_str(),si.mode)) - ThrowErrno(path + ": can't set mode"); - return true; + return GetErrno(path + ": can't set mode", ErrStr); + return false; } void |