summaryrefslogtreecommitdiffstats
path: root/src/H5R.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/H5R.c')
-rw-r--r--src/H5R.c19
1 files changed, 13 insertions, 6 deletions
diff --git a/src/H5R.c b/src/H5R.c
index 2fa4fd2..0ba7898 100644
--- a/src/H5R.c
+++ b/src/H5R.c
@@ -87,15 +87,22 @@ H5R_init_interface(void)
EXAMPLES
REVISION LOG
--------------------------------------------------------------------------*/
-void
-H5R_term_interface(intn status)
+intn
+H5R_term_interface(void)
{
- if (interface_initialize_g>0) {
- /* Free ID group */
- H5I_destroy_group(H5I_REFERENCE);
+ intn n=0;
+
+ if (interface_initialize_g) {
+ if ((n=H5I_nmembers(H5I_REFERENCE))) {
+ H5I_clear_group(H5I_REFERENCE);
+ } else {
+ H5I_destroy_group(H5I_REFERENCE);
+ interface_initialize_g = 0;
+ n = 1; /*H5I*/
+ }
}
- interface_initialize_g = status;
+ return n;
}