Function: gnus-cache-delete-group

gnus-cache-delete-group is an autoloaded and byte-compiled function defined in gnus-cache.el.gz.

Signature

(gnus-cache-delete-group GROUP)

Documentation

Delete GROUP from the cache.

Always updates the cache, even when disabled, as the old cache files would corrupt gnus when the cache was next enabled. Depends upon the caller to determine whether group deletion is supported.

Source Code

;; Defined in /usr/src/emacs/lisp/gnus/gnus-cache.el.gz
;;;###autoload
(defun gnus-cache-delete-group (group)
  "Delete GROUP from the cache.
Always updates the cache, even when disabled, as the old cache
files would corrupt gnus when the cache was next enabled.
Depends upon the caller to determine whether group deletion is
supported."
  (let ((dir (gnus-cache-file-name group ""))
	(file-name-coding-system nnmail-pathname-coding-system))
    (gnus-delete-directory dir))

  (gnus-cache-delete-group-total-fetched-for group)

  (let ((no-save gnus-cache-active-hashtb))
    (unless gnus-cache-active-hashtb
      (gnus-cache-read-active))
    (let* ((group-hash-value (gethash group gnus-cache-active-hashtb)))
      (remhash group gnus-cache-active-hashtb)

      (if no-save
	  (setq gnus-cache-active-altered group-hash-value)
	(gnus-cache-write-active group-hash-value)))))