buffer: fix not return on error
authorTrevor Norris <trev.norris@gmail.com>
Wed, 22 Jul 2015 19:06:54 +0000 (13:06 -0600)
committerRod Vagg <rod@vagg.org>
Tue, 4 Aug 2015 18:56:16 +0000 (11:56 -0700)
commite6ab2d92bc15c0f122ddc9310a9d69499008703a
tree8eec8ddee104a2a25e0361fef3baec45bff0fb32
parent9f727f5e03bbe6f798f0a084bf318f78f064013d
buffer: fix not return on error

Throwing a JS error from C++ does not mean the function will return
early. This must be done manually.

Also remove extraneous comment no longer relevant.

Fix: 2903030 "buffer: switch API to return MaybeLocal<T>"
PR-URL: https://github.com/nodejs/io.js/pull/2225
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
src/node_buffer.cc