diff options
author | Lars Magne Ingebrigtsen <larsi@gnus.org> | 1996-07-02 23:37:45 +0000 |
---|---|---|
committer | Lars Magne Ingebrigtsen <larsi@gnus.org> | 1996-07-02 23:37:45 +0000 |
commit | ceddd3fd68e88a881467f47ce784a18f124fbc0a (patch) | |
tree | 8fb9a56dedaa414534bc2d3f58eadd4b4645d2da /lisp/gnus-cache.el | |
parent | 5bb005953ee367510e74c5c2a30e954d5446f167 (diff) | |
download | emacs-ceddd3fd68e88a881467f47ce784a18f124fbc0a.tar.gz |
* gnus-cache.el (gnus-cache-possibly-alter-active): Check for
gnus-cache-active-hashtb before using it.
Diffstat (limited to 'lisp/gnus-cache.el')
-rw-r--r-- | lisp/gnus-cache.el | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/lisp/gnus-cache.el b/lisp/gnus-cache.el index d44c4949d15..24b38c64667 100644 --- a/lisp/gnus-cache.el +++ b/lisp/gnus-cache.el @@ -236,13 +236,14 @@ variable to \"^nnml\".") (defun gnus-cache-possibly-alter-active (group active) "Alter the ACTIVE info for GROUP to reflect the articles in the cache." - (let ((cache-active (gnus-gethash group gnus-cache-active-hashtb))) - (and cache-active - (< (car cache-active) (car active)) - (setcar active (car cache-active))) - (and cache-active - (> (cdr cache-active) (cdr active)) - (setcdr active (cdr cache-active))))) + (when gnus-cache-active-hashtb + (let ((cache-active (gnus-gethash group gnus-cache-active-hashtb))) + (and cache-active + (< (car cache-active) (car active)) + (setcar active (car cache-active))) + (and cache-active + (> (cdr cache-active) (cdr active)) + (setcdr active (cdr cache-active)))))) (defun gnus-cache-retrieve-headers (articles group &optional fetch-old) "Retrieve the headers for ARTICLES in GROUP." |