summaryrefslogtreecommitdiffstats
path: root/tools/lib
diff options
context:
space:
mode:
authorJonathan Kim <jkm@hdfgroup.org>2010-01-21 20:39:03 (GMT)
committerJonathan Kim <jkm@hdfgroup.org>2010-01-21 20:39:03 (GMT)
commit1eac1391e2e1b217839d31f124a5404ef94221db (patch)
tree74e1e8990dd4af23fd60b793b08584a22b924fe9 /tools/lib
parent969c86f29d342ecf208f6f4e3a153b63b0070e3b (diff)
downloadhdf5-1eac1391e2e1b217839d31f124a5404ef94221db.zip
hdf5-1eac1391e2e1b217839d31f124a5404ef94221db.tar.gz
hdf5-1eac1391e2e1b217839d31f124a5404ef94221db.tar.bz2
[svn-r18135] Purpose:
Additional fix relted to the fix of bug1672. Description: The fix of bug1672 caused some changes of output which required modifying some test cases. After some discussion, restoring the changes of the test cases was decided. After many experiments for the solution, this fix was made so the code which improved performance can stay. Tested on Jam.
Diffstat (limited to 'tools/lib')
-rw-r--r--tools/lib/h5diff.c6
-rw-r--r--tools/lib/h5diff_attr.c6
2 files changed, 8 insertions, 4 deletions
diff --git a/tools/lib/h5diff.c b/tools/lib/h5diff.c
index 18dd1ed..89823e5 100644
--- a/tools/lib/h5diff.c
+++ b/tools/lib/h5diff.c
@@ -931,11 +931,13 @@ hsize_t diff(hid_t file1_id,
/* the rest (-c, none, ...) */
else
{
- do_print_objname("dataset", path1, path2);
nfound = diff_dataset(file1_id, file2_id, path1, path2, options);
/* not comparable, no display the different number */
- if (!options->not_cmp)
+ if (!options->not_cmp && nfound)
+ {
+ do_print_objname("dataset", path1, path2);
print_found(nfound);
+ }
}
break;
diff --git a/tools/lib/h5diff_attr.c b/tools/lib/h5diff_attr.c
index 73a7ee7..2cf6539 100644
--- a/tools/lib/h5diff_attr.c
+++ b/tools/lib/h5diff_attr.c
@@ -242,7 +242,6 @@ hsize_t diff_attr(hid_t loc1_id,
/* the rest (-c, none, ...) */
else
{
- do_print_objname ("attribute", np1, np2);
nfound = diff_array(buf1,
buf2,
nelmts1,
@@ -257,8 +256,11 @@ hsize_t diff_attr(hid_t loc1_id,
attr2_id);
/* not comparable, no display the different number */
- if (!options->not_cmp)
+ if (!options->not_cmp && nfound)
+ {
+ do_print_objname ("attribute", np1, np2);
print_found(nfound);
+ }
}