From a19e02be5e3fc41aee1ecee73a26d363e186e36e Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Tue, 13 Jan 2009 22:21:14 +0000 Subject: - Michael Wallner fixed a NULL pointer deref when calling curl_easy_setup(curl, CURLOPT_COOKIELIST, "SESS") on a CURL handle with no cookies data. --- lib/cookie.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/cookie.c') diff --git a/lib/cookie.c b/lib/cookie.c index 4db1a5621..4f768f2db 100644 --- a/lib/cookie.c +++ b/lib/cookie.c @@ -5,7 +5,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1998 - 2008, Daniel Stenberg, , et al. + * Copyright (C) 1998 - 2009, Daniel Stenberg, , et al. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution. The terms @@ -878,7 +878,7 @@ void Curl_cookie_clearsess(struct CookieInfo *cookies) { struct Cookie *first, *curr, *next, *prev = NULL; - if(!cookies->cookies) + if(!cookies->cookies || !cookies->cookies) return; first = curr = prev = cookies->cookies; -- cgit v1.2.3