summaryrefslogtreecommitdiffstats
path: root/src/H5private.h
diff options
context:
space:
mode:
authorAlbert Cheng <acheng@hdfgroup.org>2010-08-03 23:35:42 (GMT)
committerAlbert Cheng <acheng@hdfgroup.org>2010-08-03 23:35:42 (GMT)
commit41f0057dbc1bb5333b6a41ed9d5a4d1942964808 (patch)
tree7e13e5933db3a0b58db06536f1a94d2801bd5949 /src/H5private.h
parent2d8a18a1fdac369b39f8160eb22b1562406e31de (diff)
downloadhdf5-41f0057dbc1bb5333b6a41ed9d5a4d1942964808.zip
hdf5-41f0057dbc1bb5333b6a41ed9d5a4d1942964808.tar.gz
hdf5-41f0057dbc1bb5333b6a41ed9d5a4d1942964808.tar.bz2
[svn-r19167] Bug fix: 1917.
Description: test/big incorrectly determined not able to write files larger than 2GB and skipped the SEC2 and STDIO driver tests. The reason was because it was using off_t while the SEC2 driver is using lseek64 which expects off64_t type. Solution: Created a new HDoff_t which is set to off_t or off64_t or other appropriate type depending on which of lseek or lseek64 is available. Changed SEC2 file driver and the big test to use this common definition. Tested: In BP (AIX), using --enable and --disable-largefile, for both 32 and 64 bits modes. Did not do h5committest because: 1. the error was exposed in the remote BP machine; 2. the change is trivial. Note that STDIO driver failed when --disable-largefile is used. That is an error in the STDIO driver code that is being fixed.
Diffstat (limited to 'src/H5private.h')
-rw-r--r--src/H5private.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/H5private.h b/src/H5private.h
index 5b8d123..e6da2cc 100644
--- a/src/H5private.h
+++ b/src/H5private.h
@@ -914,9 +914,16 @@ H5_DLL int HDfprintf (FILE *stream, const char *fmt, ...);
#endif /* HDlongjmp */
#ifndef HDlseek
#ifdef H5_HAVE_LSEEK64
- #define HDlseek(F,O,W) lseek64(F,O,W)
+ #define HDlseek(F,O,W) lseek64(F,O,W)
+ #define HDoff_t off64_t
#else
- #define HDlseek(F,O,W) lseek(F,O,W)
+ #define HDlseek(F,O,W) lseek(F,O,W)
+ #if defined (_WIN32) && !defined(__MWERKS__)
+ # /*MSVC*/
+ # define HDoff_t __int64
+ #else
+ # define HDoff_t off_t
+ #endif
#endif
#endif /* HDlseek */
#ifndef HDmalloc