title: About NodeJS Buffers
body: <p>Question about buffers.
  if i have this native code:</p>
  <pre><code>unsigned char* data = static_cast&lt;unsigned char*&gt;(malloc(sizeof(int) * 4));
  Napi::Buffer&lt;unsigned char&gt; buffer = Napi::Buffer::New(info.Env(), data, sizeof(int) * 4); // create buffer
  
  return buffer;
  </code></pre>
  <p>it would return the buffer to js, does the GC handle the <code>malloc</code>'d data? or would it cause a leak since i didn't free it. The reason i asked this here is because i am dealing with <strong>js</strong> buffers</p>