+2000-09-03 Simon Josefsson <simon@josefsson.org>
+
+ * gnus-sum.el (gnus-summary-delete-article): Check server.
+
2000-09-01 Simon Josefsson <simon@josefsson.org>
+ * imap.el (imap-parse-flag-list): Rewrite.
+
* nnimap.el (nnimap-retrieve-headers-from-file): Ignore errors.
* imap.el (imap-parse-flag-list): Hack.
(unless (gnus-check-backend-function 'request-expire-articles
gnus-newsgroup-name)
(error "The current newsgroup does not support article deletion"))
+ (unless (gnus-check-server (gnus-find-method-for-group gnus-newsgroup-name))
+ (error "Couldn't open server"))
;; Compute the list of articles to delete.
(let ((articles (sort (copy-sequence (gnus-summary-work-articles n)) '<))
not-deleted)
;; ; revisions of this specification.
(defun imap-parse-flag-list ()
- (let ((str (buffer-substring (point) (search-forward ")" nil t)))
- pos)
- (while (setq pos (string-match "\\\\" str (and pos (+ 2 pos))))
- (setq str (replace-match "\\\\" nil t str)))
- ;; xxx ugly. rewrite not to use `read' at all.
- (when (= (length (symbol-name (read "A?A"))) 1)
- (while (setq pos (string-match "\\?" str (and pos (+ 2 pos))))
- (setq str (replace-match "\\?" nil t str))))
- (mapcar 'symbol-name (read str))))
+ (let (flag-list start)
+ (when (eq (char-after) ?\()
+ (imap-forward)
+ (while (and (not (eq (char-before) ?\)))
+ (setq start (point))
+ (> (skip-chars-forward "^ )" (gnus-point-at-eol)) 0))
+ (push (buffer-substring start (point)) flag-list)
+ (imap-forward))
+ (nreverse flag-list))))
;; envelope = "(" env-date SP env-subject SP env-from SP env-sender SP
;; env-reply-to SP env-to SP env-cc SP env-bcc SP