summaryrefslogtreecommitdiffstats
path: root/test/vfd_swmr.c
diff options
context:
space:
mode:
authorDavid Young <dyoung@hdfgroup.org>2020-04-07 15:51:00 (GMT)
committerDavid Young <dyoung@hdfgroup.org>2020-04-07 15:51:00 (GMT)
commit3aaa7a4f279f5605d547fea52e03e43f08b2c8e6 (patch)
tree8a261b36d73db795eb30d233b734ac2301f80709 /test/vfd_swmr.c
parenta3262d2274f890b18ada2b4629822deec77fa9b7 (diff)
downloadhdf5-3aaa7a4f279f5605d547fea52e03e43f08b2c8e6.zip
hdf5-3aaa7a4f279f5605d547fea52e03e43f08b2c8e6.tar.gz
hdf5-3aaa7a4f279f5605d547fea52e03e43f08b2c8e6.tar.bz2
Don't try to free a NULL pointer.
Diffstat (limited to 'test/vfd_swmr.c')
-rw-r--r--test/vfd_swmr.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/vfd_swmr.c b/test/vfd_swmr.c
index 5a9b55b..755788b 100644
--- a/test/vfd_swmr.c
+++ b/test/vfd_swmr.c
@@ -2743,7 +2743,8 @@ test_shadow_index_lookup(void)
idx[j].hdf5_page_offset, cursize, seed);
nerrors++;
}
- free(idx);
+ if (idx != NULL)
+ free(idx);
}
(void)setstate(ostate);
out: