summaryrefslogtreecommitdiffstats
path: root/tools/misc/h5debug.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/misc/h5debug.c')
-rw-r--r--tools/misc/h5debug.c34
1 files changed, 20 insertions, 14 deletions
diff --git a/tools/misc/h5debug.c b/tools/misc/h5debug.c
index 9c9153a..f758b1f 100644
--- a/tools/misc/h5debug.c
+++ b/tools/misc/h5debug.c
@@ -5,12 +5,10 @@
* *
* This file is part of HDF5. The full HDF5 copyright notice, including *
* terms governing use, modification, and redistribution, is contained in *
- * the files COPYING and Copyright.html. COPYING can be found at the root *
- * of the source code distribution tree; Copyright.html can be found at the *
- * root level of an installed copy of the electronic HDF5 document set and *
- * is linked from the top-level documents page. It can also be found at *
- * http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have *
- * access to either file, you may request a copy from help@hdfgroup.org. *
+ * the COPYING file, which can be found at the root of the source code *
+ * distribution tree, or in https://support.hdfgroup.org/ftp/HDF5/releases. *
+ * If you do not have access to either file, you may request a copy from *
+ * help@hdfgroup.org. *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
/*-------------------------------------------------------------------------
@@ -57,15 +55,15 @@
/*-------------------------------------------------------------------------
* Function: get_H5B2_class
*
- * Purpose: Determine the v2 B-tree class from the buffer read in.
+ * Purpose: Determine the v2 B-tree class from the buffer read in.
* B-trees are debugged through the B-tree subclass. The subclass
* identifier is two bytes after the B-tree signature.
*
- * Return: Non-NULL on success/NULL on failure
+ * Return: Non-NULL on success/NULL on failure
*
- * Programmer: Quincey Koziol
- * koziol@hdfgroup.org
- * Sep 11 2008
+ * Programmer: Quincey Koziol
+ * koziol@hdfgroup.org
+ * Sep 11 2008
*
*-------------------------------------------------------------------------
*/
@@ -143,16 +141,18 @@ get_H5B2_class(const uint8_t *sig)
int
main(int argc, char *argv[])
{
- hid_t fid, fapl, dxpl;
+ hid_t fid, fapl, dxpl;
H5F_t *f;
haddr_t addr = 0, extra = 0, extra2 = 0, extra3 = 0, extra4 = 0;
uint8_t sig[H5F_SIGNATURE_LEN];
size_t u;
+ H5E_auto2_t func;
+ void *edata;
herr_t status = SUCCEED;
if(argc == 1) {
- HDfprintf(stderr, "Usage: %s filename [signature-addr [extra]]\n", argv[0]);
- HDexit(1);
+ HDfprintf(stderr, "Usage: %s filename [signature-addr [extra]]\n", argv[0]);
+ HDexit(1);
} /* end if */
/* Initialize the library */
@@ -161,6 +161,10 @@ main(int argc, char *argv[])
HDexit(1);
} /* end if */
+ /* Disable error reporting */
+ H5Eget_auto2(H5E_DEFAULT, &func, &edata);
+ H5Eset_auto2(H5E_DEFAULT, NULL, NULL);
+
/*
* Open the file and get the file descriptor.
*/
@@ -448,6 +452,8 @@ main(int argc, char *argv[])
H5Pclose(fapl);
H5Fclose(fid);
+ H5Eset_auto2(H5E_DEFAULT, func, edata);
+
return 0;
} /* main() */