diff options
author | David Young <dyoung@hdfgroup.org> | 2020-04-16 20:30:27 (GMT) |
---|---|---|
committer | David Young <dyoung@hdfgroup.org> | 2020-04-16 20:30:27 (GMT) |
commit | 21f3fae46982195f88b37471896bb68668dff633 (patch) | |
tree | 7650bda6a9dbfe5619ee1cf459decd2eec34eee8 /test/vfd_swmr_common.c | |
parent | 86be273386b23c56300dd53705524eb269127b4a (diff) | |
download | hdf5-21f3fae46982195f88b37471896bb68668dff633.zip hdf5-21f3fae46982195f88b37471896bb68668dff633.tar.gz hdf5-21f3fae46982195f88b37471896bb68668dff633.tar.bz2 |
Refactor: extract subroutine estack_get_state() for reuse in a commit
that's coming soon.
Diffstat (limited to 'test/vfd_swmr_common.c')
-rw-r--r-- | test/vfd_swmr_common.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/test/vfd_swmr_common.c b/test/vfd_swmr_common.c index 5625dd3..f851110 100644 --- a/test/vfd_swmr_common.c +++ b/test/vfd_swmr_common.c @@ -49,10 +49,19 @@ dbgf(int level, const char *fmt, ...) estack_state_t disable_estack(void) { + estack_state_t es = estack_get_state(); + + (void)H5Eset_auto(H5E_DEFAULT, NULL, NULL); + + return es; +} + +estack_state_t +estack_get_state(void) +{ estack_state_t es; (void)H5Eget_auto(H5E_DEFAULT, &es.efunc, &es.edata); - (void)H5Eset_auto(H5E_DEFAULT, NULL, NULL); return es; } |