mirror of
https://github.com/curl/curl.git
synced 2024-12-15 06:40:09 +08:00
cookie: fix memory leak on oversized rejection
Regression brought by 2bc230de63
Detected by OSS-fuzz: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=3513
Assisted-by: Max Dymond
Closes #1930
This commit is contained in:
parent
49d75a4c15
commit
20ea22ff73
@ -438,7 +438,7 @@ Curl_cookie_add(struct Curl_easy *data,
|
||||
/* too long individual name or contents, or too long combination of
|
||||
name + contents. Chrome and Firefox support 4095 or 4096 bytes
|
||||
combo. */
|
||||
free(co);
|
||||
freecookie(co);
|
||||
infof(data, "oversized cookie dropped, name/val %d + %d bytes\n",
|
||||
nlen, len);
|
||||
return NULL;
|
||||
|
Loading…
Reference in New Issue
Block a user