Skip to content

Commit

Permalink
src: replace handle dereference with ContainerOf
Browse files Browse the repository at this point in the history
this was influenced by #32269

PR-URL: #32298
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
  • Loading branch information
HarshithaKP authored and addaleax committed Mar 30, 2020
1 parent 7d4ec42 commit 06bff18
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/process_wrap.cc
Original file line number Diff line number Diff line change
Expand Up @@ -292,8 +292,7 @@ class ProcessWrap : public HandleWrap {
static void OnExit(uv_process_t* handle,
int64_t exit_status,
int term_signal) {
ProcessWrap* wrap = static_cast<ProcessWrap*>(handle->data);
CHECK_NOT_NULL(wrap);
ProcessWrap* wrap = ContainerOf(&ProcessWrap::process_, handle);
CHECK_EQ(&wrap->process_, handle);

Environment* env = wrap->env();
Expand Down

0 comments on commit 06bff18

Please sign in to comment.