Skip to content

Commit

Permalink
src: fix warn_unused_result compiler warning
Browse files Browse the repository at this point in the history
../src/node_file.cc:386:7: warning: ignoring return value of
function declared with 'warn_unused_result'
attribute [-Wunused-result]

PR-URL: nodejs#32241
Refs: nodejs#31972
Reviewed-By: Sam Roberts <[email protected]>
Reviewed-By: David Carlier <[email protected]>
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: James M Snell <[email protected]>
  • Loading branch information
cjihrig committed Mar 15, 2020
1 parent 86f146a commit 8617508
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 @@ -383,8 +383,8 @@ int FileHandle::ReadStart() {
// Use a fresh async resource.
// Lifetime is ensured via AsyncWrap::resource_.
Local<Object> resource = Object::New(env()->isolate());
resource->Set(
env()->context(), env()->handle_string(), read_wrap->object());
USE(resource->Set(
env()->context(), env()->handle_string(), read_wrap->object()));
read_wrap->AsyncReset(resource);
read_wrap->file_handle_ = this;
} else {
Expand Down

0 comments on commit 8617508

Please sign in to comment.