[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] master c3ca885: Divert to call `gnus-activate-group' with
From: |
Lars Ingebrigtsen |
Subject: |
[Emacs-diffs] master c3ca885: Divert to call `gnus-activate-group' with the SCAN argument set |
Date: |
Sun, 15 Apr 2018 10:13:20 -0400 (EDT) |
branch: master
commit c3ca885f4931a3b17b7e826cc866550d264d685a
Author: Daiki Ueno <address@hidden>
Commit: Lars Ingebrigtsen <address@hidden>
Divert to call `gnus-activate-group' with the SCAN argument set
* lisp/gnus/gnus-group.el (gnus-group-get-new-news-this-group):
Divert to call `gnus-activate-group' with the SCAN argument set,
if request-group-scan is not defined for the backend. Ensure that
the server is open when calling `gnus-request-group-scan'
(bug#22649).
---
lisp/gnus/gnus-group.el | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/lisp/gnus/gnus-group.el b/lisp/gnus/gnus-group.el
index 1a36468..d1f258f 100644
--- a/lisp/gnus/gnus-group.el
+++ b/lisp/gnus/gnus-group.el
@@ -4105,9 +4105,14 @@ If DONT-SCAN is non-nil, scan non-activated groups as
well."
(gnus-group-remove-mark group)
;; Bypass any previous denials from the server.
(gnus-remove-denial (setq method (gnus-find-method-for-group group)))
- (if (or (and (not dont-scan)
- (gnus-request-group-scan group (gnus-get-info group)))
- (gnus-activate-group group (if dont-scan nil 'scan) nil method))
+ (if (if (and (not dont-scan)
+ ;; Prefer request-group-scan if the backend supports it.
+ (gnus-check-backend-function 'request-group-scan group))
+ (progn
+ ;; Ensure that the server is already open.
+ (gnus-activate-group group nil nil method)
+ (gnus-request-group-scan group (gnus-get-info group)))
+ (gnus-activate-group group (if dont-scan nil 'scan) nil method))
(let ((info (gnus-get-info group))
(active (gnus-active group)))
(when info
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] master c3ca885: Divert to call `gnus-activate-group' with the SCAN argument set,
Lars Ingebrigtsen <=