Skip to content

Commit

Permalink
fs: minor improvements to O_DSYNC
Browse files Browse the repository at this point in the history
  • Loading branch information
tniessen committed Sep 22, 2017
1 parent 3888a57 commit 34cf33a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
7 changes: 4 additions & 3 deletions doc/api/fs.md
Original file line number Diff line number Diff line change
Expand Up @@ -2806,12 +2806,13 @@ The following constants are meant for use with `fs.open()`.
</tr>
<tr>
<td><code>O_SYNC</code></td>
<td>Flag indicating that the file is opened for synchronous I/O.</td>
<td>Flag indicating that the file is opened for synchronized I/O with write
operations waiting for file integrity.</td>
</tr>
<tr>
<td><code>O_DSYNC</code></td>
<td>Flag indicating that the file is opened for synchronous I/O
with write operations waiting for data integrity.</td>
<td>Flag indicating that the file is opened for synchronized I/O with write
operations waiting for data integrity.</td>
</tr>
<tr>
<td><code>O_SYMLINK</code></td>
Expand Down
4 changes: 2 additions & 2 deletions test/parallel/test-fs-open-flags.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,10 @@ common.expectsError(
{ code: 'ERR_INVALID_OPT_VALUE', type: TypeError }
);

if (common.isLinux === true) {
if (common.isLinux) {
const file = fixtures.path('a.js');

fs.open(file, O_DSYNC, common.mustCall(function(err, fd) {
fs.open(file, O_DSYNC, common.mustCall((err, fd) => {
assert.ifError(err);
}));
}

0 comments on commit 34cf33a

Please sign in to comment.