Skip to content

Commit

Permalink
Removed unnecessary call to H5E_clear_stack (#4607)
Browse files Browse the repository at this point in the history
H5FO_opened and H5SL_search don't push errors on the stack
  • Loading branch information
qkoziol authored Jun 26, 2024
1 parent 034997c commit 59f010e
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 10 deletions.
3 changes: 0 additions & 3 deletions src/H5Dint.c
Original file line number Diff line number Diff line change
Expand Up @@ -1494,9 +1494,6 @@ H5D_open(const H5G_loc_t *loc, hid_t dapl_id)

/* Check if dataset was already open */
if (NULL == (shared_fo = (H5D_shared_t *)H5FO_opened(dataset->oloc.file, dataset->oloc.addr))) {
/* Clear any errors from H5FO_opened() */
H5E_clear_stack();

/* Open the dataset object */
if (H5D__open_oid(dataset, dapl_id) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_NOTFOUND, NULL, "not found");
Expand Down
4 changes: 0 additions & 4 deletions src/H5Gint.c
Original file line number Diff line number Diff line change
Expand Up @@ -437,10 +437,6 @@ H5G_open(const H5G_loc_t *loc)

/* Check if group was already open */
if ((shared_fo = (H5G_shared_t *)H5FO_opened(grp->oloc.file, grp->oloc.addr)) == NULL) {

/* Clear any errors from H5FO_opened() */
H5E_clear_stack();

/* Open the group object */
if (H5G__open_oid(grp) < 0)
HGOTO_ERROR(H5E_SYM, H5E_NOTFOUND, NULL, "not found");
Expand Down
3 changes: 0 additions & 3 deletions src/H5Tcommit.c
Original file line number Diff line number Diff line change
Expand Up @@ -1036,9 +1036,6 @@ H5T_open(const H5G_loc_t *loc)

/* Check if datatype was already open */
if (NULL == (shared_fo = (H5T_shared_t *)H5FO_opened(loc->oloc->file, loc->oloc->addr))) {
/* Clear any errors from H5FO_opened() */
H5E_clear_stack();

/* Open the datatype object */
if (NULL == (dt = H5T__open_oid(loc)))
HGOTO_ERROR(H5E_DATATYPE, H5E_NOTFOUND, NULL, "not found");
Expand Down

0 comments on commit 59f010e

Please sign in to comment.