Skip to content

Commit dec383a

Browse files
tniessenMylesBorins
authored andcommitted
doc,test: minor improvements to O_DSYNC
Backport-PR-URL: #15653 PR-URL: #15547 Refs: #15451 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]>
1 parent 8ec81a8 commit dec383a

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

doc/api/fs.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2867,12 +2867,13 @@ The following constants are meant for use with `fs.open()`.
28672867
</tr>
28682868
<tr>
28692869
<td><code>O_SYNC</code></td>
2870-
<td>Flag indicating that the file is opened for synchronous I/O.</td>
2870+
<td>Flag indicating that the file is opened for synchronized I/O with write
2871+
operations waiting for file integrity.</td>
28712872
</tr>
28722873
<tr>
28732874
<td><code>O_DSYNC</code></td>
2874-
<td>Flag indicating that the file is opened for synchronous I/O
2875-
with write operations waiting for data integrity.</td>
2875+
<td>Flag indicating that the file is opened for synchronized I/O with write
2876+
operations waiting for data integrity.</td>
28762877
</tr>
28772878
<tr>
28782879
<td><code>O_SYMLINK</code></td>

test/parallel/test-fs-open-flags.js

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -79,12 +79,10 @@ assert.throws(
7979
/^Error: Unknown file open flag: null$/
8080
);
8181

82-
if (common.isLinux === true) {
82+
if (common.isLinux) {
8383
const file = `${__dirname}/../fixtures/a.js`;
8484

85-
fs.open(file, O_DSYNC, common.mustCall(function(err, fd) {
86-
assert.ifError(err);
87-
}));
85+
fs.open(file, O_DSYNC, common.mustCall(assert.ifError));
8886
}
8987

9088
function escapeRegExp(string) {

0 commit comments

Comments
 (0)