Changeset 1329
- Timestamp:
- May 30, 2008, 12:55:46 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/0.4-stable/yat/utility/FileUtil.cc
r1261 r1329 31 31 #include <iostream> 32 32 #include <stdexcept> 33 #include <sstream> 33 34 #include <string> 34 35 … … 87 88 { 88 89 struct stat statt; 89 if ( stat(path_.c_str(),&statt) && (errno!=ENOENT) ) 90 throw IO_error(std::string("stat(2) call failed with errno: "+errno)); 90 if ( stat(path_.c_str(),&statt) && (errno!=ENOENT) ) { 91 std::stringstream ss; 92 ss << "stat(2) call failed with errno: " << errno; 93 throw IO_error(ss.str()); 94 } 91 95 if (errno) { 92 96 errno = 0; // don't leave errno in state of failure
Note: See TracChangeset
for help on using the changeset viewer.