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 006513c commit 8eeca49Copy full SHA for 8eeca49
1 file changed
lib/iolog/iolog_open.c
@@ -70,7 +70,9 @@ iolog_open(struct iolog_file *iol, int dfd, int iofd, const char *mode)
70
"%s: invalid iofd %d", __func__, iofd);
71
debug_return_bool(false);
72
}
73
- if (iofd == IOFD_TIMING && ISSET(flags, O_WRONLY|O_RDWR)) {
+
74
+ /* Lock the timing file if opening for writing. */
75
+ if (iofd == IOFD_TIMING && (mode[0] == 'w' || mode[1] == '+')) {
76
lockit = true;
77
78
0 commit comments