aboutsummaryrefslogtreecommitdiffstats
path: root/cookie.c
diff options
context:
space:
mode:
authorDavid Crosby <dave@dafyddcrosby.com>2015-07-10 02:55:19 +0000
committerTatsuya Kinoshita <tats@debian.org>2015-08-11 12:59:27 +0000
commit80b38e6bc3fe5a2441ffaa6df68f8cfc87c4e681 (patch)
treeb1891de89bc16691730a85f0449afdec625a63b6 /cookie.c
parentFix resource leak (diff)
downloadw3m-80b38e6bc3fe5a2441ffaa6df68f8cfc87c4e681.tar.gz
w3m-80b38e6bc3fe5a2441ffaa6df68f8cfc87c4e681.zip
Fix resource leak in load_cookies
Diffstat (limited to '')
-rw-r--r--cookie.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/cookie.c b/cookie.c
index cd0c38c..20dcb2a 100644
--- a/cookie.c
+++ b/cookie.c
@@ -518,36 +518,36 @@ load_cookies(void)
cookie->commentURL = NULL;
parseURL(readcol(&str)->ptr, &cookie->url, NULL);
if (!*str)
- return;
+ break;
cookie->name = readcol(&str);
if (!*str)
- return;
+ break;
cookie->value = readcol(&str);
if (!*str)
- return;
+ break;
cookie->expires = (time_t) atol(readcol(&str)->ptr);
if (!*str)
- return;
+ break;
cookie->domain = readcol(&str);
if (!*str)
- return;
+ break;
cookie->path = readcol(&str);
if (!*str)
- return;
+ break;
cookie->flag = atoi(readcol(&str)->ptr);
if (!*str)
- return;
+ break;
cookie->version = atoi(readcol(&str)->ptr);
if (!*str)
- return;
+ break;
cookie->comment = readcol(&str);
if (cookie->comment->length == 0)
cookie->comment = NULL;
if (!*str)
- return;
+ break;
cookie->portl = make_portlist(readcol(&str));
if (!*str)
- return;
+ break;
cookie->commentURL = readcol(&str);
if (cookie->commentURL->length == 0)
cookie->commentURL = NULL;