Changeset 924 for trunk/src/vpb/FileUtils.cpp
- Timestamp:
- 08/05/08 15:41:53 (4 years ago)
- Files:
-
- 1 modified
-
trunk/src/vpb/FileUtils.cpp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/vpb/FileUtils.cpp
r920 r924 2 2 #include <vpb/BuildLog> 3 3 #include <osgDB/FileUtils> 4 #include <osgDB/FileNameUtils> 4 5 5 6 #ifdef WIN32 … … 138 139 139 140 } 141 142 bool vpb::hasWritePermission(const std::string& filename) 143 { 144 log(osg::NOTICE,"vpb::access(%s, W_OK)=%i",filename.c_str(), vpb::access(filename.c_str(), W_OK)); 145 146 if (vpb::access(filename.c_str(), W_OK)==0) return true; 147 148 std::string path = osgDB::getFilePath(filename); 149 if (path.empty()) path = "."; 150 151 log(osg::NOTICE,"vpb::access(%s, W_OK)=%i",path.c_str(), vpb::access(path.c_str(), W_OK)); 152 153 return (vpb::access(path.c_str(), W_OK)==0); 154 } 155
