summaryrefslogtreecommitdiffstats
path: root/tools/h5dump
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2010-08-05 23:19:01 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2010-08-05 23:19:01 (GMT)
commit0de252524dfec1028bdd9241dbd4cca46535b93a (patch)
treecb9df4f6d8db74ee263e82459e562037c26de611 /tools/h5dump
parent1fe94ec545b2ae92fefc16eb3d9864e52b12107d (diff)
downloadhdf5-0de252524dfec1028bdd9241dbd4cca46535b93a.zip
hdf5-0de252524dfec1028bdd9241dbd4cca46535b93a.tar.gz
hdf5-0de252524dfec1028bdd9241dbd4cca46535b93a.tar.bz2
[svn-r19179] Description:
Bring changes from Coverity branch back to trunk: r19079 & 19080: [BZ1942] h5dump -u to generate XML, it does not respect the -m option xml version of dump_data function didn't check for use of fp_format variable. Added new test expected file for committed bug 1942 r19103, 19104 & 19105: [BZ1821] h5repack -v did not display correct output for a selected compression. Needed new test for comparing output of -v option. Added new test file for solution to BZ1821 BZ1821 - Bring test changes from the shell script actually used. Tested on: Mac OS X/32 10.6.4 (amazon) debug & production (h5committested on branch)
Diffstat (limited to 'tools/h5dump')
-rw-r--r--tools/h5dump/h5dump.c6
-rwxr-xr-xtools/h5dump/testh5dumpxml.sh.in3
2 files changed, 9 insertions, 0 deletions
diff --git a/tools/h5dump/h5dump.c b/tools/h5dump/h5dump.c
index e4c5231..4abc0b0 100644
--- a/tools/h5dump/h5dump.c
+++ b/tools/h5dump/h5dump.c
@@ -5429,6 +5429,12 @@ xml_dump_data(hid_t obj_id, int obj_data, struct subset_t UNUSED * sset, int UNU
int depth;
int stdindent = COL; /* should be 3 */
+ if (fp_format)
+ {
+ outputformat->fmt_double = fp_format;
+ outputformat->fmt_float = fp_format;
+ }
+
if (nCols==0) {
outputformat->line_ncols = 65535;
outputformat->line_per_line = 1;
diff --git a/tools/h5dump/testh5dumpxml.sh.in b/tools/h5dump/testh5dumpxml.sh.in
index c4c8657..c9f1ad2 100755
--- a/tools/h5dump/testh5dumpxml.sh.in
+++ b/tools/h5dump/testh5dumpxml.sh.in
@@ -188,6 +188,9 @@ TOOLTEST torderattr2.h5.xml --xml -H --sort_by=name --sort_order=descending tord
TOOLTEST torderattr3.h5.xml --xml -H --sort_by=creation_order --sort_order=ascending torderattr.h5
TOOLTEST torderattr4.h5.xml --xml -H --sort_by=creation_order --sort_order=descending torderattr.h5
+# tests for floating point user defined printf format
+TOOLTEST tfpformat.h5.xml -u -m %.7f tfpformat.h5
+
if test $nerrors -eq 0 ; then
echo "All $TESTNAME tests passed."