;;; gnus-int.el --- backend interface functions for Gnus
-;; Copyright (C) 1996,97 Free Software Foundation, Inc.
+;; Copyright (C) 1996,97,98 Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@ifi.uio.no>
;; Keywords: news
(require 'gnus)
(defcustom gnus-open-server-hook nil
- "Hook called just before opening connection to the news server."
+ "*Hook called just before opening connection to the news server."
:group 'gnus-start
:type 'hook)
(t
(require 'nntp)))
(setq gnus-current-select-method gnus-select-method)
- (run-hooks 'gnus-open-server-hook)
+ (gnus-run-hooks 'gnus-open-server-hook)
(or
;; gnus-open-server-hook might have opened it
(gnus-server-opened gnus-select-method)
(gnus-message 5 "Opening %s server%s..." (car method)
(if (equal (nth 1 method) "") ""
(format " on %s" (nth 1 method)))))
- (run-hooks 'gnus-open-server-hook)
+ (gnus-run-hooks 'gnus-open-server-hook)
(prog1
(gnus-open-server method)
(unless silent
(defun gnus-request-scan (group gnus-command-method)
"Request a SCAN being performed in GROUP from GNUS-COMMAND-METHOD.
If GROUP is nil, all groups on GNUS-COMMAND-METHOD are scanned."
- (let ((gnus-command-method
- (if group (gnus-find-method-for-group group) gnus-command-method))
- (gnus-inhibit-demon t))
- (funcall (gnus-get-function gnus-command-method 'request-scan)
- (and group (gnus-group-real-name group))
- (nth 1 gnus-command-method))))
+ (when gnus-plugged
+ (let ((gnus-command-method
+ (if group (gnus-find-method-for-group group) gnus-command-method))
+ (gnus-inhibit-demon t))
+ (funcall (gnus-get-function gnus-command-method 'request-scan)
+ (and group (gnus-group-real-name group))
+ (nth 1 gnus-command-method)))))
(defsubst gnus-request-update-info (info gnus-command-method)
"Request that GNUS-COMMAND-METHOD update INFO."
article (gnus-group-real-name group)
(nth 1 gnus-command-method) accept-function last)))
-(defun gnus-request-accept-article (group gnus-command-method &optional last)
+(defun gnus-request-accept-article (group &optional gnus-command-method last)
;; Make sure there's a newline at the end of the article.
(when (stringp gnus-command-method)
(setq gnus-command-method (gnus-server-to-method gnus-command-method)))