Changeset 3342
- Timestamp:
- 11/12/09 16:25:37 (4 months ago)
- Files:
-
- 1 modified
-
MOAB/trunk/ReadHDF5.cpp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
MOAB/trunk/ReadHDF5.cpp
r3272 r3342 62 62 #define READ_HDF5_BUFFER_SIZE (40*1024*1024) 63 63 64 #if !defined(WIN32) && !defined(WIN64) 65 # include <sys/stat.h> 66 # include <unistd.h> 67 # include <errno.h> 68 #endif 69 64 70 // This function doesn't do anything useful. It's just a nice 65 71 // place to set a break point to determine why the reader fails. … … 258 264 } 259 265 else { 266 267 // first check if file exists, so we can fail w/out 268 // a lot of noise from the HDF5 library if it does not 269 #if !defined(WIN32) && !defined(WIN64) 270 struct stat junk; 271 if (stat( filename, &junk)) { 272 if (ENOENT == errno) 273 return MB_FILE_DOES_NOT_EXIST; 274 else 275 return MB_FILE_WRITE_ERROR; 276 } 277 else if (S_ISDIR(junk.st_mode)) 278 return MB_FILE_DOES_NOT_EXIST; 279 #endif 280 260 281 // Open the file 261 282 filePtr = mhdf_openFile( filename, 0, NULL, &status );
![(please configure the [header_logo] section in trac.ini)](/projects/ITAPS/chrome/common/trac_banner.png)