aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2003-08-14 15:06:36 +0000
committerDaniel Stenberg <daniel@haxx.se>2003-08-14 15:06:36 +0000
commitacbcd68d89c1613b012f4b765eefda5770404ff5 (patch)
treeeb197d1c3f88e7757dd482a653e642f02005a14d
parent4281470fca67dd51ffba1799d303e2eedaa1efa8 (diff)
Curl_SSL_InitSessions can return error, so check the return code and bail
out if necessary
-rw-r--r--lib/transfer.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/transfer.c b/lib/transfer.c
index f33660812..463ca9d65 100644
--- a/lib/transfer.c
+++ b/lib/transfer.c
@@ -1502,6 +1502,7 @@ Transfer(struct connectdata *conn)
CURLcode Curl_pretransfer(struct SessionHandle *data)
{
+ CURLcode res;
if(!data->change.url)
/* we can't do anything wihout URL */
return CURLE_URL_MALFORMAT;
@@ -1510,7 +1511,11 @@ CURLcode Curl_pretransfer(struct SessionHandle *data)
/* Init the SSL session ID cache here. We do it here since we want to
do it after the *_setopt() calls (that could change the size) but
before any transfer. */
- Curl_SSL_InitSessions(data, data->set.ssl.numsessions);
+ res = Curl_SSL_InitSessions(data, data->set.ssl.numsessions);
+ if(res)
+ return res;
+#else
+ (void)res;
#endif
data->set.followlocation=0; /* reset the location-follow counter */