fuwaneko / node-protobuf

Google Protocol Buffers wrapper for Node.js [UNMAINTAINED]
181 stars 42 forks source link

Fix crash mentioned in ticket #53 #54

Closed szilardhuber closed 8 years ago

szilardhuber commented 8 years ago

The Nan update for node v4.2.1 caused a crash on garbage collection due to misuse of Nan::NewBuffer.

According to the Nan documentation:

Note that when creating a Buffer using Nan::NewBuffer() and an existing char*, it is assumed that the ownership of the pointer is being transferred to the new Buffer for management.