Commit d44540f5 authored by Trevor Norris's avatar Trevor Norris Committed by Myles Borins
Browse files

buffer: standardize array index check

ParseArrayIndex() was requesting a Uint32Value(), but assigning it to an
in32_t. This caused slight differences in error message reported in edge
cases of argument parsing. Fixed by getting the IntegerValue() before
checking if the value is < 0. Added test of API that was affected.

PR-URL: https://github.com/nodejs/node/pull/6084


Reviewed-By: default avatarJames M Snell <jasnell@gmail.com>
parent 440d1172
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment