Skip to content
This repository has been archived by the owner on Oct 16, 2021. It is now read-only.

Commit

Permalink
build: fix --without-ssl compile time error
Browse files Browse the repository at this point in the history
Fix the following build error by putting #if guards around the
variables:

    ../src/node.cc: In function 'void node::ParseArgs(int*,
    const char**, int*, const char***, int*, const char***)':
    ../src/node.cc:3037:7: error: 'SSL2_ENABLE' was not declared
    in this scope
           SSL2_ENABLE = true;
           ^
    ../src/node.cc:3039:7: error: 'SSL3_ENABLE' was not declared
    in this scope
           SSL3_ENABLE = true;

Fixes: nodejs#8645
PR-URL: nodejs/node#3825
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
Reviewed-By: James M Snell <jasnell@gmail.com>
  • Loading branch information
bnoordhuis authored and jBarz committed Nov 4, 2016
1 parent 3e359f3 commit b048049
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/node.cc
Original file line number Diff line number Diff line change
Expand Up @@ -3034,9 +3034,13 @@ static void ParseArgs(int* argc,
printf("%s\n", NODE_VERSION);
exit(0);
} else if (strcmp(arg, "--enable-ssl2") == 0) {
#if HAVE_OPENSSL
SSL2_ENABLE = true;
#endif
} else if (strcmp(arg, "--enable-ssl3") == 0) {
#if HAVE_OPENSSL
SSL3_ENABLE = true;
#endif
} else if (strcmp(arg, "--help") == 0 || strcmp(arg, "-h") == 0) {
PrintHelp();
exit(0);
Expand Down

0 comments on commit b048049

Please sign in to comment.