Skip to content

Commit 13b14f5

Browse files
authored
Merge pull request #3906 from edgargabriel/pr/lazy_open_fix
common/ompio: fix the lazy_open flag
2 parents 931c202 + 8e17827 commit 13b14f5

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

ompi/mca/common/ompio/common_ompio_file_open.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -200,12 +200,12 @@ int mca_common_ompio_file_open (ompi_communicator_t *comm,
200200
!mca_io_ompio_sharedfp_lazy_open ) {
201201
shared_fp_base_module = ompio_fh->f_sharedfp;
202202
ret = shared_fp_base_module->sharedfp_seek(ompio_fh,current_size, MPI_SEEK_SET);
203-
}
204-
else {
205-
opal_output(1, "mca_common_ompio_file_open: Could not adjust position of "
206-
"shared file pointer with MPI_MODE_APPEND\n");
207-
ret = MPI_ERR_OTHER;
208-
goto fn_fail;
203+
if ( MPI_SUCCESS != ret ) {
204+
opal_output(1, "mca_common_ompio_file_open: Could not adjust position of "
205+
"shared file pointer with MPI_MODE_APPEND\n");
206+
ret = MPI_ERR_OTHER;
207+
goto fn_fail;
208+
}
209209
}
210210
}
211211

0 commit comments

Comments
 (0)