Skip to content

Commit

Permalink
src: fix compiler warning in process.ppid
Browse files Browse the repository at this point in the history
This commit fixes a compiler warning with SetAccessor() by
passing in the context.

Backport-PR-URL: #21760
PR-URL: #16958
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Gireesh Punathil <[email protected]>
Reviewed-By: Timothy Gu <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Daniel Bevenius <[email protected]>
Reviewed-By: Franziska Hinkelmann <[email protected]>
  • Loading branch information
cjihrig authored and rvagg committed Aug 16, 2018
1 parent abcc911 commit 6f545d1
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/node.cc
Original file line number Diff line number Diff line change
Expand Up @@ -3514,8 +3514,9 @@ void SetupProcessObject(Environment* env,
Integer::New(env->isolate(), uv_os_getpid()));
READONLY_PROPERTY(process, "features", GetFeatures(env));

process->SetAccessor(FIXED_ONE_BYTE_STRING(env->isolate(), "ppid"),
GetParentProcessId);
CHECK(process->SetAccessor(env->context(),
FIXED_ONE_BYTE_STRING(env->isolate(), "ppid"),
GetParentProcessId).FromJust());

auto scheduled_immediate_count =
FIXED_ONE_BYTE_STRING(env->isolate(), "_scheduledImmediateCount");
Expand Down

0 comments on commit 6f545d1

Please sign in to comment.