X-Git-Url: http://git.chise.org/gitweb/?a=blobdiff_plain;f=lisp%2Fpop3.el;h=7d120e0ddc99f4fbaf0d06484b3e92b75354e8b6;hb=1744f2fbe4c382d63068903cd867804bd2485d3e;hp=ef872898bd15c5eb4a0acec416eb88e1979abecc;hpb=a539ef5f22a99ad8e8e04ffabb8b97507cb730de;p=elisp%2Fgnus.git- diff --git a/lisp/pop3.el b/lisp/pop3.el index ef87289..7d120e0 100644 --- a/lisp/pop3.el +++ b/lisp/pop3.el @@ -511,27 +511,6 @@ If NOW, use that time instead." (if (not (and response (string-match "+OK" response))) (pop3-quit process)))) -;; When this file is being compiled in the Gnus (not T-gnus) source -;; tree, `md5' might have been defined in w3/md5.el, ./lpath.el or one -;; of some other libraries and `md5' will accept only 3 arguments. We -;; will deceive the byte-compiler not to say warnings. -(eval-when-compile - (if (boundp 'byte-compile-function-environment) - (let ((def (assq 'md5 byte-compile-function-environment))) - (if def - (setcdr def '(lambda (object &optional start end - coding-system noerror))) - (setq byte-compile-function-environment - (cons '(md5 . (lambda (object &optional start end - coding-system noerror))) - byte-compile-function-environment)))))) - -;; Note that `pop3-md5' should never encode a given string to use for the -;; apop authentication, so we should specify the `binary' coding system. -(eval-and-compile - (defalias 'pop3-md5 (lambda (string) - (md5 string nil nil 'binary)))) - (defun pop3-apop (process user) "Send alternate authentication information to the server." (let ((pass pop3-password)) @@ -539,7 +518,9 @@ If NOW, use that time instead." (setq pass (read-passwd (format "Password for %s: " pop3-maildrop)))) (if pass - (let ((hash (pop3-md5 (concat pop3-timestamp pass)))) + ;; Note that `md5' should never encode a given string to use for + ;; the apop authentication, so we should specify `binary'. + (let ((hash (md5 (concat pop3-timestamp pass) nil nil 'binary))) (pop3-send-command process (format "APOP %s %s" user hash)) (let ((response (pop3-read-response process t))) (if (not (and response (string-match "+OK" response)))