# HG changeset patch # User Chong Yidong <cyd@stupidchicken.com> # Date 1291502501 18000 # Node ID 3d34c0b303ff717eae14f6db2ca7999bd83fb9ab # Parent 4bb97b6fa4d3cac9e0f0ae947142381f1db27175 * url-cookie.el (url-cookie-retrieve): Handle null LOCALPART (Bug#7543). Suggested by Lennart Borgman. diff -r 4bb97b6fa4d3 -r 3d34c0b303ff lisp/url/ChangeLog --- a/lisp/url/ChangeLog Sat Dec 04 16:45:17 2010 -0500 +++ b/lisp/url/ChangeLog Sat Dec 04 17:41:41 2010 -0500 @@ -1,3 +1,8 @@ +2010-12-04 Chong Yidong <cyd@stupidchicken.com> + + * url-cookie.el (url-cookie-retrieve): Handle null LOCALPART. + Suggested by Lennart Borgman (Bug#7543). + 2010-09-18 Glenn Morris <rgm@gnu.org> * url-cache.el (url-is-cached): Doc fix. diff -r 4bb97b6fa4d3 -r 3d34c0b303ff lisp/url/url-cookie.el --- a/lisp/url/url-cookie.el Sat Dec 04 16:45:17 2010 -0500 +++ b/lisp/url/url-cookie.el Sat Dec 04 17:41:41 2010 -0500 @@ -198,7 +198,7 @@ (and exp (> (float-time) (float-time (date-to-time exp)))))) (defun url-cookie-retrieve (host &optional localpart secure) - "Retrieve all the netscape-style cookies for a specified HOST and LOCALPART." + "Retrieve all cookies for a specified HOST and LOCALPART." (let ((storage (if secure (append url-cookie-secure-storage url-cookie-storage) url-cookie-storage)) @@ -226,7 +226,8 @@ (setq cur (car cookies) cookies (cdr cookies) localpart-match (url-cookie-localpart cur)) - (if (and (if (stringp localpart-match) + (if (and (if (and (stringp localpart-match) + (stringp localpart)) (string-match (concat "^" (regexp-quote localpart-match)) localpart)