Skip to content

Commit

Permalink
Fix bug in MPI-IO VFD (HDFGroup#4456)
Browse files Browse the repository at this point in the history
Corrects incorrect usage of the vector_was_sorted parameter in H5FD__mpio_vector_build_types()
  • Loading branch information
qkoziol authored May 2, 2024
1 parent eeaee6d commit 76211b2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/H5FDmpio.c
Original file line number Diff line number Diff line change
Expand Up @@ -1804,7 +1804,7 @@ H5FD__mpio_vector_build_types(uint32_t count, H5FD_mem_t types[], haddr_t addrs[
/* Determine size of this vector element */
if (!fixed_size) {
if ((*s_sizes)[i] == 0) {
assert(vector_was_sorted);
assert(*vector_was_sorted);
assert(i > 0);
fixed_size = true;
size = sizes[i - 1];
Expand Down Expand Up @@ -1951,7 +1951,7 @@ H5FD__mpio_vector_build_types(uint32_t count, H5FD_mem_t types[], haddr_t addrs[

done:
/* free sorted vectors if they exist */
if (!vector_was_sorted)
if (!*vector_was_sorted)
if (s_types) {
free(s_types);
s_types = NULL;
Expand Down

0 comments on commit 76211b2

Please sign in to comment.