diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/H5Tconv.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/H5Tconv.c b/src/H5Tconv.c index 43d9dd2..0444d2c 100644 --- a/src/H5Tconv.c +++ b/src/H5Tconv.c @@ -2238,8 +2238,8 @@ H5T_conv_vlen(hid_t src_id, hid_t dst_id, H5T_cdata_t *cdata, hsize_t nelmts, d = *dptr; /* Get length of element sequences */ - seq_len=(*(src->u.vlen.getlen))(src->u.vlen.f,s); - assert(seq_len>=0); + if((seq_len=(*(src->u.vlen.getlen))(src->u.vlen.f,s))<0) + HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "null pointer"); H5_CHECK_OVERFLOW(seq_len,hssize_t,size_t); src_size=(size_t)seq_len*src_base_size; dst_size=(size_t)seq_len*dst_base_size; |