Skip to content

Commit

Permalink
src: fix coverity warnings in node_file.cc
Browse files Browse the repository at this point in the history
Fix two warnings about a useless call and not checking
a return value.

Signed-off-by: Michael Dawson <[email protected]>

PR-URL: #42272
Reviewed-By: Tobias Nießen <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Rich Trott <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Darshan Sen <[email protected]>
  • Loading branch information
mhdawson authored and danielleadams committed Apr 24, 2022
1 parent 5b30e28 commit 7fe16ec
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/node_file.cc
Original file line number Diff line number Diff line change
Expand Up @@ -277,13 +277,13 @@ inline void FileHandle::Close() {
detail.fd);
if (env->filehandle_close_warning()) {
env->set_filehandle_close_warning(false);
ProcessEmitDeprecationWarning(
USE(ProcessEmitDeprecationWarning(
env,
"Closing a FileHandle object on garbage collection is deprecated. "
"Please close FileHandle objects explicitly using "
"FileHandle.prototype.close(). In the future, an error will be "
"thrown if a file descriptor is closed during garbage collection.",
"DEP0137").IsNothing();
"DEP0137"));
}
}, CallbackFlags::kUnrefed);
}
Expand Down

0 comments on commit 7fe16ec

Please sign in to comment.