]> granicus.if.org Git - curl/commitdiff
Fixed compilation when HTTP or cookies are disabled
authorDan Fandrich <dan@coneharvesters.com>
Fri, 21 Oct 2011 00:54:18 +0000 (17:54 -0700)
committerDan Fandrich <dan@coneharvesters.com>
Fri, 21 Oct 2011 00:54:18 +0000 (17:54 -0700)
lib/share.c
lib/url.c

index 59f33eb108ef42cb79710d574f78dc3fa1024f23..71c2ef308fdb7c66f34cf7776dbb3a142fbb8964 100644 (file)
@@ -194,8 +194,10 @@ curl_share_cleanup(CURLSH *sh)
     share->hostcache = NULL;
   }
 
+#if !defined(CURL_DISABLE_HTTP) && !defined(CURL_DISABLE_COOKIES)
   if(share->cookies)
     Curl_cookie_cleanup(share->cookies);
+#endif
 
 #ifdef USE_SSL
   if(share->sslsession) {
index 8ccef459a215862d60ed9a92636615b796171dd9..c3beaaa6ffeb44244836b814caebbb0fb1cbe5cc 100644 (file)
--- a/lib/url.c
+++ b/lib/url.c
@@ -2094,8 +2094,10 @@ CURLcode Curl_setopt(struct SessionHandle *data, CURLoption option,
         data->dns.hostcachetype = HCACHE_NONE;
       }
 
+#if !defined(CURL_DISABLE_HTTP) && !defined(CURL_DISABLE_COOKIES)
       if(data->share->cookies == data->cookies)
         data->cookies = NULL;
+#endif
 
       if(data->share->sslsession == data->state.session) {
         data->state.session = NULL;