diff options
Diffstat (limited to 'tools/misc')
-rw-r--r-- | tools/misc/h5debug.c | 54 | ||||
-rw-r--r-- | tools/misc/h5repart.c | 4 | ||||
-rw-r--r-- | tools/misc/talign.c | 4 |
3 files changed, 30 insertions, 32 deletions
diff --git a/tools/misc/h5debug.c b/tools/misc/h5debug.c index 6b043ba..9c9153a 100644 --- a/tools/misc/h5debug.c +++ b/tools/misc/h5debug.c @@ -21,33 +21,31 @@ * * Purpose: Debugs an existing HDF5 file at a low level. * - * Modifications: - * *------------------------------------------------------------------------- */ -#define H5A_PACKAGE /*suppress error about including H5Apkg */ -#define H5B2_PACKAGE /*suppress error about including H5B2pkg */ -#define H5B2_TESTING /*suppress warning about H5B2 testing funcs*/ +#define H5A_PACKAGE /*suppress error about including H5Apkg */ +#define H5B2_PACKAGE /*suppress error about including H5B2pkg */ +#define H5B2_TESTING /*suppress warning about H5B2 testing funcs*/ #define H5D_PACKAGE /*suppress error about including H5Dpkg */ -#define H5F_PACKAGE /*suppress error about including H5Fpkg */ -#define H5G_PACKAGE /*suppress error about including H5Gpkg */ -#define H5HF_PACKAGE /*suppress error about including H5HFpkg */ -#define H5O_PACKAGE /*suppress error about including H5Opkg */ -#define H5SM_PACKAGE /*suppress error about including H5SMpkg */ - -#include "H5private.h" /* Generic Functions */ -#include "H5Apkg.h" /* Attributes */ -#include "H5B2pkg.h" /* v2 B-trees */ -#include "H5Dpkg.h" /* Datasets */ -#include "H5Eprivate.h" /* Error handling */ -#include "H5Fpkg.h" /* File access */ -#include "H5FSprivate.h" /* Free space manager */ -#include "H5Gpkg.h" /* Groups */ -#include "H5HFpkg.h" /* Fractal heaps */ -#include "H5HGprivate.h" /* Global Heaps */ -#include "H5Iprivate.h" /* IDs */ -#include "H5Opkg.h" /* Object headers */ -#include "H5SMpkg.h" /* Implicitly shared messages */ +#define H5F_PACKAGE /*suppress error about including H5Fpkg */ +#define H5G_PACKAGE /*suppress error about including H5Gpkg */ +#define H5HF_PACKAGE /*suppress error about including H5HFpkg */ +#define H5O_PACKAGE /*suppress error about including H5Opkg */ +#define H5SM_PACKAGE /*suppress error about including H5SMpkg */ + +#include "H5private.h" /* Generic Functions */ +#include "H5Apkg.h" /* Attributes */ +#include "H5B2pkg.h" /* v2 B-trees */ +#include "H5Dpkg.h" /* Datasets */ +#include "H5Eprivate.h" /* Error handling */ +#include "H5Fpkg.h" /* File access */ +#include "H5FSprivate.h" /* Free space manager */ +#include "H5Gpkg.h" /* Groups */ +#include "H5HFpkg.h" /* Fractal heaps */ +#include "H5HGprivate.h" /* Global Heaps */ +#include "H5Iprivate.h" /* IDs */ +#include "H5Opkg.h" /* Object headers */ +#include "H5SMpkg.h" /* Implicitly shared messages */ /* File drivers */ #include "H5FDfamily.h" @@ -192,13 +190,13 @@ main(int argc, char *argv[]) * Parse command arguments. */ if(argc > 2) - addr = HDstrtoll(argv[2], NULL, 0); + addr = (haddr_t)HDstrtoll(argv[2], NULL, 0); if(argc > 3) - extra = HDstrtoll(argv[3], NULL, 0); + extra = (haddr_t)HDstrtoll(argv[3], NULL, 0); if(argc > 4) - extra2 = HDstrtoll(argv[4], NULL, 0); + extra2 = (haddr_t)HDstrtoll(argv[4], NULL, 0); if(argc > 5) - extra3 = HDstrtoll(argv[5], NULL, 0); + extra3 = (haddr_t)HDstrtoll(argv[5], NULL, 0); if(argc > 6) extra4 = (haddr_t)HDstrtoll(argv[6], NULL, 0); diff --git a/tools/misc/h5repart.c b/tools/misc/h5repart.c index 07f6bfd..ffd52e8 100644 --- a/tools/misc/h5repart.c +++ b/tools/misc/h5repart.c @@ -290,7 +290,7 @@ main (int argc, char *argv[]) if (argno<argc) usage (prog_name); /* Now the real work, split the file */ - buf = malloc (blk_size); + buf = HDmalloc (blk_size); while (src_offset<src_size) { /* Read a block. The amount to read is the minimum of: @@ -498,6 +498,6 @@ main (int argc, char *argv[]) } /* Free resources and return */ - free (buf); + HDfree (buf); return EXIT_SUCCESS; } diff --git a/tools/misc/talign.c b/tools/misc/talign.c index 3fd1694..2d0a9d1 100644 --- a/tools/misc/talign.c +++ b/tools/misc/talign.c @@ -126,7 +126,7 @@ int main(void) H5Dclose(set); /* Now open the set, and read it back in */ - data = (char *)malloc(H5Tget_size(fix)); + data = (char *)HDmalloc(H5Tget_size(fix)); if(!data) { perror("malloc() failed"); @@ -192,7 +192,7 @@ out: } if(data) - free(data); + HDfree(data); H5Sclose(spc); H5Tclose(cmp); H5Tclose(cmp1); |