Skip to content
This repository was archived by the owner on Oct 15, 2020. It is now read-only.

Conversation

@kunalspathak
Copy link
Member

Merge 3e17884 as of 2017-06-22.

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines
Affected core subsystem(s)

core, n-api, test

Eugene Ostroukhov and others added 7 commits June 21, 2017 11:20
Error value was not checked. Turns out, uv_ip6_addr was actually called
on malformed IP (square brackets should not have been included).

PR-URL: nodejs/node#13799
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Mention that the staging branch should be rebased on top of the release
branch after merging a release proposal.

PR-URL: nodejs/node#13742
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Fixes `this.push(undefined)`.

Fixes: nodejs/node#13753
PR-URL: nodejs/node#13760
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Calvin Metcalf <calvin.metcalf@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
V8 will crash if escape is called twice on the same
scope.

Add checks to avoid crashing if napi_escape_scope() is
called to try and do this.

Add test that tries to call napi_create_scope() twice.

PR-URL: nodejs/node#13651
Reviewed-By: Jason Ginchereau <jasongin@microsoft.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
PR-URL: nodejs/node#13820
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: David Cai <davidcai1993@yahoo.com>
This seems to have been removed inadvertently by
330c8d7 in PR 12925.

PR-URL: nodejs/node#13838
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
The error message might be misleading if an object property
was the issue and not the argument itself.

Fix this by checking if a argument or a property is passed
to the handler function.

PR-URL: nodejs/node#13730
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>

static_assert(
sizeof(error_messages) / sizeof(*error_messages) == napi_status_last,
node::arraysize(error_messages) == napi_escape_called_twice + 1,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's an upstream PR to eliminate node_internal.h from node_api.h, we should probably avoid taking any further dependency on it.

nodejs/node#13892

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Although taking another look it seems like there's some discussion ongoing, so we can leave this for now.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, i just adopted this changes from node_api.cc.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, that PR was closed now and we're going a different direction. LGTM as is.

Copy link
Contributor

@kfarnung kfarnung left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with minor changes.

chakrabot and others added 3 commits June 29, 2017 11:51
Merge 3e17884 as of 2017-06-22.
This is an automatically created merge. For any problems please
contact @kunalspathak.

PR-URL: nodejs#321
Reviewed-By: Kyle Farnung <kfarnung@microsoft.com>
Removed usage of `napi_status_last` from `node_api_jsrt.cc` and replaced with
`node::array`

PR-URL: nodejs#321
Reviewed-By: Kyle Farnung <kfarnung@microsoft.com>
jsrt napi doesn't implement `napi_open_escapable_handle_scope`.
When we escape handle scope twice, we should throw, but there is
no place to store the information.

Hence skipping the check for now.

PR-URL: nodejs#321
Reviewed-By: Kyle Farnung <kfarnung@microsoft.com>
@kunalspathak kunalspathak merged commit ffa055e into nodejs:master Jun 29, 2017
kfarnung pushed a commit to kfarnung/node-chakracore that referenced this pull request Jul 5, 2017
Removed usage of `napi_status_last` from `node_api_jsrt.cc` and replaced with
`node::array`

PR-URL: nodejs#321
Reviewed-By: Kyle Farnung <kfarnung@microsoft.com>
kfarnung pushed a commit to kfarnung/node-chakracore that referenced this pull request Jul 6, 2017
jsrt napi doesn't implement `napi_open_escapable_handle_scope`.
When we escape handle scope twice, we should throw, but there is
no place to store the information.

Hence skipping the check for now.

PR-URL: nodejs#321
Reviewed-By: Kyle Farnung <kfarnung@microsoft.com>
kfarnung pushed a commit to kfarnung/node-chakracore that referenced this pull request Jul 6, 2017
Removed usage of `napi_status_last` from `node_api_jsrt.cc` and replaced with
`node::array`

PR-URL: nodejs#321
Reviewed-By: Kyle Farnung <kfarnung@microsoft.com>
kfarnung pushed a commit to kfarnung/node-chakracore that referenced this pull request Jul 6, 2017
jsrt napi doesn't implement `napi_open_escapable_handle_scope`.
When we escape handle scope twice, we should throw, but there is
no place to store the information.

Hence skipping the check for now.

PR-URL: nodejs#321
Reviewed-By: Kyle Farnung <kfarnung@microsoft.com>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants