aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lisp/net/gnutls.el15
1 files changed, 9 insertions, 6 deletions
diff --git a/lisp/net/gnutls.el b/lisp/net/gnutls.el
index ccaef8aafac..a7321da854c 100644
--- a/lisp/net/gnutls.el
+++ b/lisp/net/gnutls.el
@@ -193,12 +193,7 @@ defaults to GNUTLS_VERIFY_ALLOW_X509_V1_CA_CRT."
193 ;; The gnutls library doesn't understand files delivered via 193 ;; The gnutls library doesn't understand files delivered via
194 ;; the special handlers, so ignore all files found via those. 194 ;; the special handlers, so ignore all files found via those.
195 (file-name-handler-alist nil) 195 (file-name-handler-alist nil)
196 (trustfiles (or trustfiles 196 (trustfiles (or trustfiles (gnutls-trustfiles)))
197 (delq nil
198 (mapcar (lambda (f) (and f (file-exists-p f) f))
199 (if (functionp gnutls-trustfiles)
200 (funcall gnutls-trustfiles)
201 gnutls-trustfiles)))))
202 (priority-string (or priority-string 197 (priority-string (or priority-string
203 (cond 198 (cond
204 ((eq type 'gnutls-anon) 199 ((eq type 'gnutls-anon)
@@ -251,6 +246,14 @@ defaults to GNUTLS_VERIFY_ALLOW_X509_V1_CA_CRT."
251 246
252 process)) 247 process))
253 248
249(defun gnutls-trustfiles ()
250 "Return a list of usable trustfiles."
251 (delq nil
252 (mapcar (lambda (f) (and f (file-exists-p f) f))
253 (if (functionp gnutls-trustfiles)
254 (funcall gnutls-trustfiles)
255 gnutls-trustfiles))))
256
254(declare-function gnutls-error-string "gnutls.c" (error)) 257(declare-function gnutls-error-string "gnutls.c" (error))
255 258
256(defun gnutls-message-maybe (doit format &rest params) 259(defun gnutls-message-maybe (doit format &rest params)