Skip to content

Commit e0cf4bf

Browse files
Update iotest_nonblock.cpp
1 parent 8bcef97 commit e0cf4bf

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

utils/iotest/iotest_nonblock.cpp

+3-5
Original file line numberDiff line numberDiff line change
@@ -136,15 +136,13 @@ int mainImpl(int argc, char ** argv)
136136

137137
for (size_t i = 0; i < descriptors; ++i)
138138
{
139-
#if defined(OS_DARWIN)
139+
#if defined(OS_DARWIN)
140140
if (fsync(fds[i]))
141141
throwFromErrno("Cannot fsync", ErrorCodes::CANNOT_FSYNC);
142-
#else
142+
#else
143143
if (fdatasync(fds[i]))
144144
throwFromErrno("Cannot fdatasync", ErrorCodes::CANNOT_FSYNC);
145-
#endif
146-
if (fdatasync(fds[i]))
147-
throwFromErrno("Cannot fsync", ErrorCodes::CANNOT_FSYNC);
145+
#endif
148146
}
149147

150148
watch.stop();

0 commit comments

Comments
 (0)