Commit 04b63e02 authored by Ben Noordhuis's avatar Ben Noordhuis Committed by Trevor Norris
Browse files

lib: fix max size check in Buffer constructor

A number -> uint32 type coercion bug made buffer sizes
larger than kMaxLength (0x3fffffff) wrap around.

Instead of rejecting the requested size with an exception,
the constructor created a buffer with the wrong size.

PR-URL: https://github.com/iojs/io.js/pull/657


Reviewed-By: default avatarTrevor Norris <trev.norris@gmail.com>
parent 605329d7
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