diff options
author | Daniel Stenberg <daniel@haxx.se> | 2004-05-21 20:40:15 +0000 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2004-05-21 20:40:15 +0000 |
commit | 755f98e7687a1fc2a7ff363212803b39897897a0 (patch) | |
tree | ea9937317e931a527f550f4aa2645f4b2209c87a /lib/cookie.c | |
parent | aadc797225906ba02fab4e1ad29b484acd4751b3 (diff) |
While talking to host a.b.c, libcurl did wrongly not accept cookies that were
set to the domain .a.b.c (that is with a dot prefix). This is now fixed and
test case 171 verifies it.
Diffstat (limited to 'lib/cookie.c')
-rw-r--r-- | lib/cookie.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/cookie.c b/lib/cookie.c index 693b5f98e..d31bcd114 100644 --- a/lib/cookie.c +++ b/lib/cookie.c @@ -261,6 +261,9 @@ Curl_cookie_add(struct SessionHandle *data, /* Now, we make sure that our host is within the given domain, or the given domain is not valid and thus cannot be set. */ + if('.' == whatptr[0]) + whatptr++; /* ignore preceeding dot */ + if(!domain || tailmatch(whatptr, domain)) { const char *tailptr=whatptr; if(tailptr[0] == '.') |