summaryrefslogtreecommitdiff
path: root/lisp/net/netrc.el
diff options
context:
space:
mode:
authorMiles Bader <miles@gnu.org>2008-05-22 05:03:00 +0000
committerMiles Bader <miles@gnu.org>2008-05-22 05:03:00 +0000
commita368801ce640e7e00c6e8dcf3c71a75c270268f4 (patch)
treef77994878a790e4d01ceddb768d530251f17c741 /lisp/net/netrc.el
parentc63028e1b49f5176b2838c85d90fc1ad3d84f3f0 (diff)
downloademacs-a368801ce640e7e00c6e8dcf3c71a75c270268f4.tar.gz
Merge from gnus--devo--0
Revision: emacs@sv.gnu.org/emacs--devo--0--patch-1172
Diffstat (limited to 'lisp/net/netrc.el')
-rw-r--r--lisp/net/netrc.el6
1 files changed, 4 insertions, 2 deletions
diff --git a/lisp/net/netrc.el b/lisp/net/netrc.el
index acc5ce4665f..ae06af872b9 100644
--- a/lisp/net/netrc.el
+++ b/lisp/net/netrc.el
@@ -137,8 +137,10 @@ Entries without port tokens default to DEFAULTPORT."
(while (and result
(not (netrc-port-equal
(or port defaultport "nntp")
+ ;; when port is not given in the netrc file,
+ ;; it should mean "any port"
(or (netrc-get (car result) "port")
- defaultport "nntp"))))
+ defaultport port))))
(pop result))
(car result))))
@@ -159,7 +161,7 @@ MODE can be \"login\" or \"password\", suitable for passing to
(dolist (default defaults)
(dolist (port ports)
(let ((alist (netrc-machine authinfo-list machine port default)))
- (setq info (or (netrc-get alist mode) info))))))
+ (setq info (or (netrc-get alist mode) info))))))
info))
(defun netrc-get (alist type)