summaryrefslogtreecommitdiffstats
path: root/src/H5PB.c
diff options
context:
space:
mode:
authorDavid Young <dyoung@hdfgroup.org>2020-03-30 17:22:13 (GMT)
committerDavid Young <dyoung@hdfgroup.org>2020-03-30 18:22:17 (GMT)
commit7d50e9c89e7ef2dcfd18f8bfe7d5eb4afa91d700 (patch)
treeb2bb9b6cec2151fda1436561f75b3f540e08a6d5 /src/H5PB.c
parent78fac0241a588668fed0c8b4cde9a874c44f2d3e (diff)
downloadhdf5-7d50e9c89e7ef2dcfd18f8bfe7d5eb4afa91d700.zip
hdf5-7d50e9c89e7ef2dcfd18f8bfe7d5eb4afa91d700.tar.gz
hdf5-7d50e9c89e7ef2dcfd18f8bfe7d5eb4afa91d700.tar.bz2
Be brief: turn 7 lines of if-else to one line of ?:. Be sensible: don't
assert a pointer we just dereferenced is non-NULL.
Diffstat (limited to 'src/H5PB.c')
-rw-r--r--src/H5PB.c11
1 files changed, 1 insertions, 10 deletions
diff --git a/src/H5PB.c b/src/H5PB.c
index a8fbf4e..c81212a 100644
--- a/src/H5PB.c
+++ b/src/H5PB.c
@@ -1755,16 +1755,7 @@ H5PB_vfd_swmr__update_index(H5F_t *f,
ie_ptr->tick_of_last_change = shared->tick_num;
ie_ptr->clean = !entry->is_dirty;
- if ( ie_ptr->clean ) {
-
- ie_ptr->tick_of_last_flush = shared->tick_num;
-
- } else {
-
- ie_ptr->tick_of_last_flush = 0;
- }
-
- HDassert(ie_ptr);
+ ie_ptr->tick_of_last_flush = ie_ptr->clean ? shared->tick_num : 0;
}
/* scan the metadata file index for entries that don't appear in the