summaryrefslogtreecommitdiffstats
path: root/tools/lib
diff options
context:
space:
mode:
Diffstat (limited to 'tools/lib')
-rw-r--r--tools/lib/h5diff.c2
-rw-r--r--tools/lib/h5diff_array.c20
-rw-r--r--tools/lib/h5tools.c6
-rw-r--r--tools/lib/h5tools_dump.c6
-rw-r--r--tools/lib/h5tools_ref.c2
-rw-r--r--tools/lib/h5tools_str.c8
-rw-r--r--tools/lib/h5tools_utils.c10
-rw-r--r--tools/lib/io_timer.c7
-rw-r--r--tools/lib/ph5diff.h4
9 files changed, 16 insertions, 49 deletions
diff --git a/tools/lib/h5diff.c b/tools/lib/h5diff.c
index afb36d9..9da5b6b 100644
--- a/tools/lib/h5diff.c
+++ b/tools/lib/h5diff.c
@@ -11,8 +11,6 @@
* help@hdfgroup.org. *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-#include <stdlib.h>
-
#include "H5private.h"
#include "h5tools.h"
#include "h5tools_utils.h"
diff --git a/tools/lib/h5diff_array.c b/tools/lib/h5diff_array.c
index 0b1a96e..7236ad1 100644
--- a/tools/lib/h5diff_array.c
+++ b/tools/lib/h5diff_array.c
@@ -673,21 +673,33 @@ static hsize_t diff_datum(void *_mem1,
h5difftrace("diff_datum H5T_STRING variable\n");
/* Get pointer to first string */
s1 = *(char**) mem1;
- size1 = HDstrlen(s1);
+ if(s1)
+ size1 = HDstrlen(s1);
+ else
+ size1 = 0;
/* Get pointer to second string */
s2 = *(char**) mem2;
- size2 = HDstrlen(s2);
+ if(s2)
+ size2 = HDstrlen(s2);
+ else
+ size2 = 0;
}
else if (H5T_STR_NULLTERM == pad) {
h5difftrace("diff_datum H5T_STRING null term\n");
/* Get pointer to first string */
s1 = (char*) mem1;
- size1 = HDstrlen(s1);
+ if(s1)
+ size1 = HDstrlen(s1);
+ else
+ size1 = 0;
if (size1 > size_mtype)
size1 = size_mtype;
/* Get pointer to second string */
s2 = (char*) mem2;
- size2 = HDstrlen(s2);
+ if(s2)
+ size2 = HDstrlen(s2);
+ else
+ size2 = 0;
if (size2 > size_mtype)
size2 = size_mtype;
}
diff --git a/tools/lib/h5tools.c b/tools/lib/h5tools.c
index 3729cac..5031e44 100644
--- a/tools/lib/h5tools.c
+++ b/tools/lib/h5tools.c
@@ -12,16 +12,10 @@
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
/*
- * Programmer: Robb Matzke <matzke@llnl.gov>
- * Thursday, July 23, 1998
- *
* Purpose: A library for displaying the values of a dataset in a human
* readable format.
*/
-#include <stdio.h>
-#include <stdlib.h>
-
#include "h5tools.h"
#include "h5tools_dump.h"
#include "h5tools_ref.h"
diff --git a/tools/lib/h5tools_dump.c b/tools/lib/h5tools_dump.c
index 1a57512..fb79b77 100644
--- a/tools/lib/h5tools_dump.c
+++ b/tools/lib/h5tools_dump.c
@@ -12,16 +12,10 @@
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
/*
- * Programmer: Robb Matzke <matzke@llnl.gov>
- * Thursday, July 23, 1998
- *
* Purpose: A library for displaying the values of a dataset in a human
* readable format.
*/
-#include <stdio.h>
-#include <stdlib.h>
-
#include "h5tools.h"
#include "h5tools_dump.h"
#include "h5tools_ref.h"
diff --git a/tools/lib/h5tools_ref.c b/tools/lib/h5tools_ref.c
index 85850e3..e000080 100644
--- a/tools/lib/h5tools_ref.c
+++ b/tools/lib/h5tools_ref.c
@@ -11,8 +11,6 @@
* help@hdfgroup.org. *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-#include <stdio.h>
-#include <stdlib.h>
#include "h5tools_ref.h"
#include "H5private.h"
#include "H5SLprivate.h"
diff --git a/tools/lib/h5tools_str.c b/tools/lib/h5tools_str.c
index fa15785..a66cfe5 100644
--- a/tools/lib/h5tools_str.c
+++ b/tools/lib/h5tools_str.c
@@ -12,16 +12,8 @@
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
/*
- * Programmer: Bill Wendling <wendling@ncsa.uiuc.edu>
- * Monday, 19. February 2001
- *
* Purpose: These are string functions for us to use and abuse.
*/
-#include <stdarg.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
#include "H5private.h"
#include "h5tools.h" /* for h5tool_format_t structure */
#include "h5tools_ref.h"
diff --git a/tools/lib/h5tools_utils.c b/tools/lib/h5tools_utils.c
index c361e25..08213df 100644
--- a/tools/lib/h5tools_utils.c
+++ b/tools/lib/h5tools_utils.c
@@ -12,20 +12,10 @@
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
/*
- * Programmer: Bill Wendling <wendling@ncsa.uiuc.edu>
- * Tuesday, 6. March 2001
- */
-
-/*
* Portions of this work are derived from _Obfuscated C and Other Mysteries_,
* by Don Libes, copyright (c) 1993 by John Wiley & Sons, Inc.
*/
-#include <ctype.h>
-#include <stdarg.h>
-#include <stdio.h>
-#include <stdlib.h>
-
#include "h5tools.h"
#include "h5tools_utils.h"
#include "H5private.h"
diff --git a/tools/lib/io_timer.c b/tools/lib/io_timer.c
index e3318e9..a6885df 100644
--- a/tools/lib/io_timer.c
+++ b/tools/lib/io_timer.c
@@ -22,16 +22,9 @@
* This is a module of useful timing functions for performance testing.
*/
-#include <stdio.h>
-#include <stdlib.h>
-
#include "H5private.h"
#include "hdf5.h"
-#ifdef H5_HAVE_PARALLEL
-#include <mpi.h>
-#endif
-
#include "io_timer.h"
/*
diff --git a/tools/lib/ph5diff.h b/tools/lib/ph5diff.h
index 9628d45..996a611 100644
--- a/tools/lib/ph5diff.h
+++ b/tools/lib/ph5diff.h
@@ -42,9 +42,5 @@ struct diffs_found
int not_cmp;
};
-#ifdef H5_HAVE_PARALLEL
-#include <mpi.h>
-#endif
-
#endif /* _PH5DIFF_H__ */