buffer: construct new buffer from buffer toJSON() output
authorcjihrig <cjihrig@gmail.com>
Fri, 27 Jun 2014 04:07:16 +0000 (00:07 -0400)
committerFedor Indutny <fedor@indutny.com>
Fri, 27 Jun 2014 09:36:44 +0000 (13:36 +0400)
commit2cae44f16934836f0a66b2ea930a0604f505e571
treecc6f36bf7a5d7b3df62d16969945c9030aa01147
parent1a1b1a75347a4d68aedefb71b8bacce050b1768b
buffer: construct new buffer from buffer toJSON() output

Creating a new buffer from the toJSON() output of another
buffer does not currently work. This commit adds that
support. Closes #7849.

Signed-off-by: Fedor Indutny <fedor@indutny.com>
lib/buffer.js
test/simple/test-buffer.js