Changeset 7673 in orxonox.OLD for trunk/src/lib/util
- Timestamp:
- May 18, 2006, 11:06:17 AM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/lib/util/file.cc
r7661 r7673 146 146 this->_status = new struct stat; 147 147 // Check the End of the FileName and chop away any \ and // 148 /*std::string name = this->_name;149 if (this->_name[this->_name.size()-1] == '/' ||150 this->_name[this->_name.size()-1] == '\\')151 name.resize(name.size()-1);*/152 if (stat( this->_name.c_str(), this->_status))148 std::string name = this->_name; 149 while (name[name.size()-1] == '/' || 150 name[name.size()-1] == '\\') 151 name.resize(name.size()-1); 152 if (stat(name.c_str(), this->_status)) 153 153 { 154 154 delete this->_status; … … 206 206 // tmpDirName.erase(tmpDirName.size()-1); 207 207 //} 208 printf("DIR IS: %s ", this->name().c_str()); 209 if (this->_status) 210 printf("OK\n"); 211 else 212 printf("FUCK\n"); 213 208 214 return (this->_status != NULL && this->_status->st_mode & (S_IFDIR)); 209 215 }
Note: See TracChangeset
for help on using the changeset viewer.