diff options
author | Dana Robinson <derobins@hdfgroup.org> | 2017-11-11 05:15:50 (GMT) |
---|---|---|
committer | Dana Robinson <derobins@hdfgroup.org> | 2017-11-11 05:15:50 (GMT) |
commit | d4a0e3d293596dcd0412c7cc02f18addf44d03d5 (patch) | |
tree | 5c080f4f76f4dec7287b1c67a968c957bbfb737a /src | |
parent | 6663efbf6618f14eb66324e18a7a8e2632f96cf2 (diff) | |
parent | 3e4f6138b60d8363c377e453d63f875775ec907a (diff) | |
download | hdf5-d4a0e3d293596dcd0412c7cc02f18addf44d03d5.zip hdf5-d4a0e3d293596dcd0412c7cc02f18addf44d03d5.tar.gz hdf5-d4a0e3d293596dcd0412c7cc02f18addf44d03d5.tar.bz2 |
Merge pull request #767 in HDFFV/hdf5 from ~DEROBINS/hdf5_der:zero_allocation_fix_develop to develop
* commit '3e4f6138b60d8363c377e453d63f875775ec907a':
Removed asserts from H5MM calls that conflict with stated behavior and added a test to ensure that this doesn't happen in the future.
Diffstat (limited to 'src')
-rw-r--r-- | src/H5MM.c | 8 |
1 files changed, 1 insertions, 7 deletions
@@ -268,8 +268,6 @@ H5MM_malloc(size_t size) { void *ret_value = NULL; - HDassert(size); - /* Use FUNC_ENTER_NOAPI_NOINIT_NOERR here to avoid performance issues */ FUNC_ENTER_NOAPI_NOINIT_NOERR @@ -357,8 +355,6 @@ H5MM_calloc(size_t size) { void *ret_value = NULL; - HDassert(size); - /* Use FUNC_ENTER_NOAPI_NOINIT_NOERR here to avoid performance issues */ FUNC_ENTER_NOAPI_NOINIT_NOERR @@ -407,8 +403,6 @@ H5MM_realloc(void *mem, size_t size) /* Use FUNC_ENTER_NOAPI_NOINIT_NOERR here to avoid performance issues */ FUNC_ENTER_NOAPI_NOINIT_NOERR - HDassert(mem || size); - if(NULL == mem && 0 == size) /* Not defined in the standard, return NULL */ ret_value = NULL; @@ -454,7 +448,7 @@ H5MM_realloc(void *mem, size_t size) * NULL is an acceptable value for the input string. * * Return: Success: Pointer to a new string (NULL if s is NULL). - * Failure: abort() + * Failure: NULL * * Programmer: Robb Matzke * Jul 10 1997 |