Skip to content

Commit

Permalink
initialize NSS libraries
Browse files Browse the repository at this point in the history
  • Loading branch information
mcr authored and shussain committed Oct 29, 2018
1 parent d18f84e commit 6c51110
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
8 changes: 8 additions & 0 deletions programs/addconn/addconn.c
Expand Up @@ -226,6 +226,14 @@ main(int argc, char *argv[])
yydebug=1;
}

#ifdef HAVE_LIBNSS
SECStatus success = NSS_NoDB_Init(NULL);
if(success != SECSuccess) {
fprintf(stderr, "failed to initialize NSS, unable to proceed\n");
exit(2);
}
#endif

/* find config file */
confdir = getenv(IPSEC_CONFDIR_VAR);
if(confdir == NULL)
Expand Down
8 changes: 8 additions & 0 deletions programs/readwriteconf/readwriteconf.c
Expand Up @@ -180,6 +180,14 @@ main(int argc, char *argv[])
}
}

#ifdef HAVE_LIBNSS
SECStatus success = NSS_NoDB_Init(NULL);
if(success != SECSuccess) {
fprintf(stderr, "failed to initialize NSS, unable to proceed\n");
exit(2);
}
#endif

/* find config file */
confdir = getenv(IPSEC_CONFDIR_VAR);
if(confdir == NULL)
Expand Down

0 comments on commit 6c51110

Please sign in to comment.