Commit 9a3929dc authored by Ben Noordhuis's avatar Ben Noordhuis
Browse files

src: introduce internal Buffer::Copy() function

Rename the three argument overload of Buffer::New() to Buffer::Copy()
and update the code base accordingly.  The reason for renaming is to
make it impossible to miss a call site.

This coincidentally plugs a small memory leak in crypto.getAuthTag().

Fixes: https://github.com/nodejs/node/issues/2308
PR-URL: https://github.com/nodejs/node/pull/2352


Reviewed-By: default avatarFedor Indutny <fedor@indutny.com>
Reviewed-By: default avatarTrevor Norris <trev.norris@gmail.com>
parent b86211a8
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