From c1689dc32c75a5c8aa318d52e0a4b814bda9c5ed Mon Sep 17 00:00:00 2001 From: Matheus Marchini Date: Mon, 4 Dec 2017 19:08:15 -0200 Subject: [PATCH] build: define HAVE_OPENSSL macro for cctest cctest build target wasn't defining the HAVE_OPENSSL macro when node_use_openssl was true, causing inconsistencies on most `node::Environment` member's addresses. For example, if someone wanted to access the context of an environment by using `node::Environment::context()`, the object returned by the function was pointing to an invalid address. PR-URL: https://github.com/nodejs/node/pull/17461 Reviewed-By: Joyee Cheung Reviewed-By: Daniel Bevenius Reviewed-By: James M Snell Reviewed-By: Ruben Bridgewater Reviewed-By: Anna Henningsen --- node.gyp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/node.gyp b/node.gyp index ed28b4a6ce198a..e362b67830537f 100644 --- a/node.gyp +++ b/node.gyp @@ -864,6 +864,9 @@ '<(OBJ_PATH)<(OBJ_SEPARATOR)node_crypto_clienthello.<(OBJ_SUFFIX)', '<(OBJ_PATH)<(OBJ_SEPARATOR)tls_wrap.<(OBJ_SUFFIX)', ], + 'defines': [ + 'HAVE_OPENSSL=1', + ], }], ['v8_enable_inspector==1', { 'sources': [