diff options
Diffstat (limited to 'java/src/jni/h5eImp.c')
-rw-r--r-- | java/src/jni/h5eImp.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/java/src/jni/h5eImp.c b/java/src/jni/h5eImp.c index 24ddcbc..df7e35f 100644 --- a/java/src/jni/h5eImp.c +++ b/java/src/jni/h5eImp.c @@ -508,8 +508,12 @@ H5E_walk_cb constructor = CBENVPTR->GetMethodID(CBENVPAR cls, "<init>", "(JJJILjava/lang/String;Ljava/lang/String;Ljava/lang/String;)V"); if (constructor != 0) { cb_info_t = CBENVPTR->NewObjectA(CBENVPAR cls, constructor, args); - - status = CBENVPTR->CallIntMethod(CBENVPAR visit_callback, mid, nindx, cb_info_t, op_data); + if (cb_info_t == NULL) { + printf("FATAL ERROR: Creation failed\n"); + } + else { + status = CBENVPTR->CallIntMethod(CBENVPAR visit_callback, mid, nindx, cb_info_t, op_data); + } } /* end if (constructor != 0) */ } /* end if(cls != 0) */ } /* end if (mid != 0) */ |