diff options
author | David Young <dyoung@hdfgroup.org> | 2020-08-21 14:50:49 (GMT) |
---|---|---|
committer | David Young <dyoung@hdfgroup.org> | 2020-08-21 14:50:49 (GMT) |
commit | 88342f8b3f8658bf82ce5d25d5597f237f23c544 (patch) | |
tree | 3a055b382bb110e77868815b79e51f69339c7519 /test/vfd_swmr_generator.c | |
parent | 2fe7d17a766faab80edb4f0e094f2dc3f8210d01 (diff) | |
download | hdf5-88342f8b3f8658bf82ce5d25d5597f237f23c544.zip hdf5-88342f8b3f8658bf82ce5d25d5597f237f23c544.tar.gz hdf5-88342f8b3f8658bf82ce5d25d5597f237f23c544.tar.bz2 |
Use the safe calloc() idiom, p = calloc(1, sizeof(*p)), and do
not gratuitously cast to p's type.
Diffstat (limited to 'test/vfd_swmr_generator.c')
-rw-r--r-- | test/vfd_swmr_generator.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/test/vfd_swmr_generator.c b/test/vfd_swmr_generator.c index 13fc941..35a1ac5 100644 --- a/test/vfd_swmr_generator.c +++ b/test/vfd_swmr_generator.c @@ -144,7 +144,7 @@ gen_skeleton(const char *filename, hbool_t verbose, hbool_t vfd_swmr_write, return -1; /* Allocate memory for the VFD SWMR configuration structure */ - if((config = (H5F_vfd_swmr_config_t *)HDcalloc(1, sizeof(H5F_vfd_swmr_config_t))) == NULL) + if((config = HDcalloc(1, sizeof(*config))) == NULL) return -1; config->version = H5F__CURR_VFD_SWMR_CONFIG_VERSION; |