We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 88438f0 commit f9fa7b5Copy full SHA for f9fa7b5
src/drivers/ncmpio/ncmpio_create.c
@@ -84,9 +84,11 @@ ncmpio_create(MPI_Comm comm,
84
85
/* Check if the file already exists, if lstat() or access() is available */
86
#ifdef HAVE_LSTAT
87
- struct stat st_buf;
88
/* call lstat() to check the file if exists and if is a symbolic link */
89
if (rank == 0) {
+ struct stat st_buf;
90
+ st_buf.st_mode = 0;
91
+
92
if (lstat(filename, &st_buf) == -1) file_exist = 0;
93
errno = 0; /* reset errno */
94
0 commit comments