Importing Pterodactyl Gnus v0.89.
[elisp/gnus.git-] / lisp / gnus-srvr.el
index 849a2da..4c65009 100644 (file)
@@ -1,5 +1,5 @@
 ;;; gnus-srvr.el --- virtual server support for Gnus
-;; Copyright (C) 1995,96,97,98 Free Software Foundation, Inc.
+;; Copyright (C) 1995,96,97,98,99 Free Software Foundation, Inc.
 
 ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org>
 ;; Keywords: news
@@ -550,9 +550,9 @@ The following commands are available:
 
 (defun gnus-browse-foreign-server (server &optional return-buffer)
   "Browse the server SERVER."
-  (setq gnus-browse-current-method server)
+  (setq gnus-browse-current-method (gnus-server-to-method server))
   (setq gnus-browse-return-buffer return-buffer)
-  (let* ((method (gnus-server-to-method server))
+  (let* ((method gnus-browse-current-method)
         (gnus-select-method method)
         groups group)
     (gnus-message 5 "Connecting to %s..." (nth 1 method))
@@ -592,11 +592,10 @@ The following commands are available:
          (while (re-search-forward
                  "\\(^[^ \t]+\\)[ \t]+[0-9]+[ \t]+[0-9]+" nil t)
            (goto-char (match-end 1))
-           (condition-case ()
-               (push (cons (match-string 1)
-                           (max 0 (- (1+ (read cur)) (read cur))))
-                     groups)
-             (error nil)))))
+           (ignore-errors
+             (push (cons (match-string 1)
+                         (max 0 (- (1+ (read cur)) (read cur))))
+                   groups)))))
       (setq groups (sort groups
                         (lambda (l1 l2)
                           (string< (car l1) (car l2)))))
@@ -654,7 +653,7 @@ buffer.
          (error "Couldn't enter %s" group))
       (unless (gnus-group-read-group nil no-article group)
        (error "Couldn't enter %s" group)))))
-      
+
 (defun gnus-browse-select-group ()
   "Select the current group."
   (interactive)
@@ -706,7 +705,7 @@ buffer.
     (save-excursion
       (beginning-of-line)
       ;; If this group it killed, then we want to subscribe it.
-      (when (= (following-char) ?K)
+      (when (eq (char-after) ?K)
        (setq sub t))
       (setq group (gnus-browse-group-name))
       (when (and sub