From: ueno Date: Mon, 4 Sep 2000 17:58:10 +0000 (+0000) Subject: * lisp/mail-source.el (pop3-leave-mail-on-server): Declare. X-Git-Tag: t-gnus-6_14_5-05~14 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=983968854ed205e12c622c1b2978513c5f9485b7;p=elisp%2Fgnus.git- * lisp/mail-source.el (pop3-leave-mail-on-server): Declare. (mail-source-keyword-map): New keyword `:leave' for pop. (mail-source-fetch-pop): Refer it. * lisp/pop3.el (pop3-ssl-program-name): New variable. --- diff --git a/lisp/mail-source.el b/lisp/mail-source.el index 016fcc7..3b0e381 100644 --- a/lisp/mail-source.el +++ b/lisp/mail-source.el @@ -28,6 +28,7 @@ (eval-when-compile (require 'cl)) (require 'nnheader) (eval-and-compile + (defvar pop3-leave-mail-on-server) (autoload 'pop3-movemail "pop3") (autoload 'pop3-get-message-count "pop3")) (require 'format-spec) @@ -114,7 +115,8 @@ Common keywords should be listed here.") (:function) (:password) (:connection) - (:authentication password)) + (:authentication password) + (:leave)) (maildir (:path (or (getenv "MAILDIR") "~/Maildir/")) (:subdirs ("new" "cur")) @@ -480,7 +482,11 @@ If ARGS, PROMPT is used as an argument to `format'." (pop3-port port) (pop3-authentication-scheme (if (eq authentication 'apop) 'apop 'pass)) - (pop3-connection-type connection)) + (pop3-connection-type connection) + (pop3-leave-mail-on-server + (or leave + (and (boundp 'pop3-leave-mail-on-server) + pop3-leave-mail-on-server)))) (save-excursion (pop3-movemail mail-source-crash-box)))))) (if result (progn diff --git a/lisp/pop3.el b/lisp/pop3.el index dabe4ee..589a2ed 100644 --- a/lisp/pop3.el +++ b/lisp/pop3.el @@ -94,6 +94,12 @@ Nil means no, t means yes, not-nil-or-t means yet to be determined.") (autoload 'starttls-open-stream "starttls") (autoload 'starttls-negotiate "starttls")) +(defvar pop3-ssl-program-name + (if (exec-installed-p "openssl") + "openssl" + "ssleay") + "The program to run in a subprocess to open an SSL connection.") + (defvar pop3-ssl-program-arguments '("s_client" "-quiet") "Arguments to be passed to the program `pop3-ssl-program-name'.") @@ -188,10 +194,7 @@ Argument PORT specifies connecting port." (defun pop3-open-ssl-stream-1 (name buffer host service extra-arg) (require 'path-util) (let* ((ssl-program-name - (cond ((exec-installed-p "openssl") - "openssl") - (t - "ssleay"))) + pop3-ssl-program-name) (ssl-program-arguments `(,@pop3-ssl-program-arguments ,extra-arg "-connect" ,(format "%s:%d" host service)))