src,crypto: refactor `crypto_dh.cc`
AllocatedBuffer
from crypto_dh.cc
src,crypto: remove uses of Refs: https://github.com/nodejs/node/pull/39941
static
qualifier in crypto_dh.cc
src: remove unnecessary ZeroPadDiffieHellmanSecret()
is in an anonymous namespace, so it has
static linkage already.
crypto_dh.cc
src,crypto: handle empty maybe correctly in Buffer::Length()
dereferences the passed Local
, so calling it when the
underlying pointer is a nullptr
would lead to a crash. This fixes that
by returning early instead.
Signed-off-by: Darshan Sen raisinten@gmail.com