summaryrefslogtreecommitdiff
path: root/src/tool_metalink.c
diff options
context:
space:
mode:
authorKamil Dudka <kdudka@redhat.com>2013-12-02 17:00:35 +0100
committerKamil Dudka <kdudka@redhat.com>2013-12-02 17:03:23 +0100
commitff9b66a8d4abb2fd92b12ae8ae3e4e7f39856af7 (patch)
tree135e04603a8c1049080dfb06ea5d7722dfedea83 /src/tool_metalink.c
parente221b55f67a2e12717e911f25d1bb6c85fcebfab (diff)
downloadcurl-ff9b66a8d4abb2fd92b12ae8ae3e4e7f39856af7.tar.gz
tool_metalink: do not use HAVE_NSS_INITCONTEXT
... no longer provided by the configure script
Diffstat (limited to 'src/tool_metalink.c')
-rw-r--r--src/tool_metalink.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/tool_metalink.c b/src/tool_metalink.c
index be5fc26c4..050f59d62 100644
--- a/src/tool_metalink.c
+++ b/src/tool_metalink.c
@@ -54,9 +54,7 @@
# define MD5_CTX void *
# define SHA_CTX void *
# define SHA256_CTX void *
-# ifdef HAVE_NSS_INITCONTEXT
- static NSSInitContext *nss_context;
-# endif
+ static NSSInitContext *nss_context;
#elif (defined(__MAC_OS_X_VERSION_MAX_ALLOWED) && \
(__MAC_OS_X_VERSION_MAX_ALLOWED >= 1040)) || \
(defined(__IPHONE_OS_VERSION_MAX_ALLOWED) && \
@@ -240,7 +238,6 @@ static int nss_hash_init(void **pctx, SECOidTag hash_alg)
PK11Context *ctx;
/* we have to initialize NSS if not initialized alraedy */
-#ifdef HAVE_NSS_INITCONTEXT
if(!NSS_IsInitialized() && !nss_context) {
static NSSInitParameters params;
params.length = sizeof params;
@@ -248,7 +245,6 @@ static int nss_hash_init(void **pctx, SECOidTag hash_alg)
| NSS_INIT_NOCERTDB | NSS_INIT_NOMODDB | NSS_INIT_FORCEOPEN
| NSS_INIT_NOROOTINIT | NSS_INIT_OPTIMIZESPACE | NSS_INIT_PK11RELOAD);
}
-#endif
ctx = PK11_CreateDigestContext(hash_alg);
if(!ctx)
@@ -894,7 +890,7 @@ void clean_metalink(struct Configurable *config)
void metalink_cleanup(void)
{
-#if defined(USE_NSS) && defined(HAVE_NSS_INITCONTEXT)
+#ifdef USE_NSS
if(nss_context) {
NSS_ShutdownContext(nss_context);
nss_context = NULL;