Mercurial > emacs
changeset 60215:a2c5c861962a
Revision: miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-124
Merge from gnus--rel--5.10
Patches applied:
* miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-27
Update from CVS
2005-02-21 Reiner Steib <Reiner.Steib@gmx.de>
* lisp/gnus/gnus-art.el (gnus-parse-news-url, gnus-button-handle-news):
Handle news URL with given port correctly.
author | Miles Bader <miles@gnu.org> |
---|---|
date | Tue, 22 Feb 2005 23:15:11 +0000 |
parents | 7cc86e0f08f6 |
children | 4f937a19bf85 bf0d492ea2d5 |
files | lisp/gnus/ChangeLog lisp/gnus/gnus-art.el |
diffstat | 2 files changed, 14 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/gnus/ChangeLog Tue Feb 22 23:12:15 2005 +0000 +++ b/lisp/gnus/ChangeLog Tue Feb 22 23:15:11 2005 +0000 @@ -1,3 +1,8 @@ +2005-02-21 Reiner Steib <Reiner.Steib@gmx.de> + + * gnus-art.el (gnus-parse-news-url, gnus-button-handle-news): + Handle news URL with given port correctly. + 2005-02-19 Katsumi Yamaoka <yamaoka@jpl.org> * gnus-msg.el (gnus-copy-article-buffer): Quote decoded words
--- a/lisp/gnus/gnus-art.el Tue Feb 22 23:12:15 2005 +0000 +++ b/lisp/gnus/gnus-art.el Tue Feb 22 23:15:11 2005 +0000 @@ -6648,15 +6648,18 @@ (cons fun args))))))) (defun gnus-parse-news-url (url) - (let (scheme server group message-id articles) + (let (scheme server port group message-id articles) (with-temp-buffer (insert url) (goto-char (point-min)) (when (looking-at "\\([A-Za-z]+\\):") (setq scheme (match-string 1)) (goto-char (match-end 0))) - (when (looking-at "//\\([^/]+\\)/") + (when (looking-at "//\\([^:/]+\\)\\(:?\\)\\([0-9]+\\)?/") (setq server (match-string 1)) + (setq port (if (stringp (match-string 3)) + (string-to-number (match-string 3)) + (match-string 3))) (goto-char (match-end 0))) (cond @@ -6669,18 +6672,19 @@ (setq group (match-string 1))) (t (error "Unknown news URL syntax")))) - (list scheme server group message-id articles))) + (list scheme server port group message-id articles))) (defun gnus-button-handle-news (url) "Fetch a news URL." - (destructuring-bind (scheme server group message-id articles) + (destructuring-bind (scheme server port group message-id articles) (gnus-parse-news-url url) (cond (message-id (save-excursion (set-buffer gnus-summary-buffer) (if server - (let ((gnus-refer-article-method (list (list 'nntp server)))) + (let ((gnus-refer-article-method (list (list 'nntp server))) + (nntp-port-number (or port "nntp"))) (gnus-summary-refer-article message-id)) (gnus-summary-refer-article message-id)))) (group