summaryrefslogtreecommitdiffstats
path: root/tools/h5import
diff options
context:
space:
mode:
authorMuQun Yang <ymuqun@hdfgroup.org>2006-03-23 02:25:10 (GMT)
committerMuQun Yang <ymuqun@hdfgroup.org>2006-03-23 02:25:10 (GMT)
commitd80639dda8e676cebcd12eae2f713faa518c35d2 (patch)
tree1547190b6108b14321dfdb372d0d36159e085a79 /tools/h5import
parent54f02fdaf2e449834f48817a15c8b8a0aa8eed1f (diff)
downloadhdf5-d80639dda8e676cebcd12eae2f713faa518c35d2.zip
hdf5-d80639dda8e676cebcd12eae2f713faa518c35d2.tar.gz
hdf5-d80639dda8e676cebcd12eae2f713faa518c35d2.tar.bz2
[svn-r12140] Purpose:
portable issue on windows Description: setvbuf on visual studio 2005 needs the size to be greater or equal to 2. <description of setvbuf from msdn library> Buffer size in bytes. Allowable range: 2 <= size <= INT_MAX (2147483647). Internally, the value supplied for size is rounded down to the nearest multiple of 2. h5import used linebuffer option of setvbuf for stderr and stdout and the size is 0 by default. This causes core dump with visual 2005 on windows 64-bit. Solution: 1. Use HDsetvbuf inside h5import.c, 2. Define HDsetvbuf inside windows H5pubconf.h for windows to work around the core dump of h5import test. This is probably a bug inside visual studio 2005. Platforms tested: h5committest( shanti refuses to be connected) windows 6.0 at XP visual 2005 at XP-64bit Misc. update:
Diffstat (limited to 'tools/h5import')
-rwxr-xr-xtools/h5import/h5import.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/h5import/h5import.c b/tools/h5import/h5import.c
index 7d81779..6e233c3 100755
--- a/tools/h5import/h5import.c
+++ b/tools/h5import/h5import.c
@@ -39,8 +39,8 @@ int main(int argc, char *argv[])
const char *err8 = "Invalid size of data - %s.\n";
const char *err9 = "Cannot specify more than 30 input files in one call to h5import.\n";
- (void) setvbuf(stderr, (char *) NULL, _IOLBF, 0);
- (void) setvbuf(stdout, (char *) NULL, _IOLBF, 0);
+ (void)HDsetvbuf(stderr, (char *) NULL, _IOLBF, 0);
+ (void)HDsetvbuf(stdout, (char *) NULL, _IOLBF, 0);
#if defined __MWERKS__
argc = ccommand(&argv);