diff options
author | Pedro Vicente Nunes <pvn@hdfgroup.org> | 2008-10-16 23:24:18 (GMT) |
---|---|---|
committer | Pedro Vicente Nunes <pvn@hdfgroup.org> | 2008-10-16 23:24:18 (GMT) |
commit | 924ba14474479cacc6aa99aabb2ac81462ff6d73 (patch) | |
tree | 4a23df0c90e6e80fe37f83c17d8bb72abe49c82e /tools/h5diff/h5diff_main.c | |
parent | 208777ec89b63e27fbe34879ec43d95329301c08 (diff) | |
download | hdf5-924ba14474479cacc6aa99aabb2ac81462ff6d73.zip hdf5-924ba14474479cacc6aa99aabb2ac81462ff6d73.tar.gz hdf5-924ba14474479cacc6aa99aabb2ac81462ff6d73.tar.bz2 |
[svn-r15896] Introduced a -c flag to ignore file contents differences in the return value (return 0 id -c is present)
Introduced for h5copy validation
Tested: windows, linux
Diffstat (limited to 'tools/h5diff/h5diff_main.c')
-rw-r--r-- | tools/h5diff/h5diff_main.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/tools/h5diff/h5diff_main.c b/tools/h5diff/h5diff_main.c index eb85407..c383933 100644 --- a/tools/h5diff/h5diff_main.c +++ b/tools/h5diff/h5diff_main.c @@ -90,11 +90,18 @@ int main(int argc, const char *argv[]) ret = (nfound == 0 ? 0 : 1 ); + /* if graph difference return 1 for differences */ if ( options.contents == 0 ) ret = 1; - if(options.err_stat) + /* but return 0 for no differences if graph comparison not required */ + if ( options.m_no_contents == 1 ) + ret = 0; + + /* and return 2 for error */ + if (options.err_stat) ret = 2; + return ret; } |