Fix a problem in url.el without GnuTLS

Fixes: debbugs:19346

* lisp/url/url-http.el (url-http-parse-headers): Check that
`gnutls-available-p' is defined.
This commit is contained in:
Lars Magne Ingebrigtsen 2014-12-11 16:57:33 +01:00
parent 3e92b9882b
commit c6f03ed03d
2 changed files with 7 additions and 1 deletions

View file

@ -1,3 +1,8 @@
2014-12-11 Lars Magne Ingebrigtsen <larsi@gnus.org>
* url-http.el (url-http-parse-headers): Check that
`gnutls-available-p' is defined (bug#19346).
2014-12-09 Lars Magne Ingebrigtsen <larsi@gnus.org>
* url-http.el (url-http-parse-headers): Pass the GnuTLS status of

View file

@ -495,7 +495,8 @@ should be shown to the user."
(url-port url-current-object)
url-http-process)
;; Pass the https certificate on to the caller.
(when (gnutls-available-p)
(when (and (fboundp 'gnutls-available-p)
(gnutls-available-p))
(let ((status (gnutls-peer-status url-http-process)))
(when (or status
(plist-get (car url-callback-arguments) :peer))