From e9f3b20b64d3c2ffe2e134a5c4bf974c916472b8 Mon Sep 17 00:00:00 2001 From: Neil Fortner Date: Thu, 21 Aug 2008 17:38:46 -0500 Subject: [svn-r15515] Fix faulty error checking in call to H5I_remove(). Add prototype to the top of app_ref.c to suppress warning. Tested: kagiso --- src/H5E.c | 2 +- test/app_ref.c | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/H5E.c b/src/H5E.c index 9365035..7112d6e 100644 --- a/src/H5E.c +++ b/src/H5E.c @@ -616,7 +616,7 @@ H5E_close_msg_cb(void *obj_ptr, hid_t obj_id, void *key) /* Close the message if it is in the class being closed */ if(err_msg->cls == cls) - if(H5I_remove(obj_id) < 0) + if(NULL == H5I_remove(obj_id)) HGOTO_ERROR(H5E_ERROR, H5E_CANTREMOVE, FAIL, "unable to remove error message") done: diff --git a/test/app_ref.c b/test/app_ref.c index 209a909..cb8be6a 100644 --- a/test/app_ref.c +++ b/test/app_ref.c @@ -76,6 +76,8 @@ const char *IDNAME[T_NUMCLASSES] = { int rc[T_NUMCLASSES]; +void Abrt_Handler (int sig); + /* Handler for SIGABRT - prints the reference count on each id */ void Abrt_Handler (int UNUSED sig) -- cgit v0.12