From c32853c3d4e025f15191e26a7a91cdfa2935f446 Mon Sep 17 00:00:00 2001 From: Achim Gsell Date: Fri, 2 Jul 2010 11:54:39 +0000 Subject: [PATCH] h5priv_te_find() now return H5_NOK, if element not found --- src/h5core/h5t_hsearch.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/h5core/h5t_hsearch.c b/src/h5core/h5t_hsearch.c index cd0858c..183ca6e 100644 --- a/src/h5core/h5t_hsearch.c +++ b/src/h5core/h5t_hsearch.c @@ -134,6 +134,10 @@ h5tpriv_find_te ( &__entry, &f->t->adjacencies.te_hash) ); h5t_te_entry_t* entry = (h5t_te_entry_t*)__entry; + if (entry ==NULL) { + // not found + return H5_NOK; + } *retval = &entry->value; return H5_SUCCESS; }