nnmaildir.el (nnmaildir-request-accept-article): Don't call `unix-sync' unless it's defined.
gnus-art.el (gnus-article-stop-animations): Use `elt' instead of `aref' for XEmacs compatibiltiy.
spam.el (spam-fetch-field-fast): Rewrite slightly for clarity.
gnus-sum.el (gnus-summary-refer-thread): Since lambdas aren't closures, quote the form properly (bug#9194).
gnus-sum.el (gnus-summary-insert-new-articles): Clean up slightly.
(gnus-summary-insert-new-articles): Protect against servers that are down.
+2011-07-31 Lars Ingebrigtsen <larsi@gnus.org>
+
+ * nnmaildir.el (nnmaildir-request-accept-article): Don't call
+ `unix-sync' unless it's defined.
+
+2011-07-31 Marcus Harnisch <marcus.harnisch@gmx.net> (tiny change)
+
+ * gnus-art.el (gnus-article-stop-animations): Use `elt' instead of
+ `aref' for XEmacs compatibiltiy.
+
+2011-07-31 Lars Magne Ingebrigtsen <larsi@gnus.org>
+
+ * spam.el (spam-fetch-field-fast): Rewrite slightly for clarity.
+
+2011-07-31 Dave Abrahams <dave@boostpro.com> (tiny change)
+
+ * gnus-sum.el (gnus-summary-refer-thread): Since lambdas aren't
+ closures, quote the form properly (bug#9194).
+
+2011-07-31 Lars Magne Ingebrigtsen <larsi@gnus.org>
+
+ * gnus-sum.el (gnus-summary-insert-new-articles): Clean up slightly.
+ (gnus-summary-insert-new-articles): Protect against servers that are
+ down.
+
2011-07-29 Daniel Dehennin <daniel.dehennin@baby-gnu.org>
* mm-decode.el (mm-dissect-buffer): Add a default content-disposition
(defun gnus-article-stop-animations ()
(dolist (timer (and (boundp 'timer-list)
timer-list))
- (when (eq (aref timer 5) 'image-animate-timeout)
+ (when (eq (elt timer 5) 'image-animate-timeout)
(cancel-timer timer))))
;; Set article window start at LINE, where LINE is the number of lines
(refs (split-string (or (mail-header-references header)
"")))
(gnus-parse-headers-hook
- (lambda () (goto-char (point-min))
+ `(lambda () (goto-char (point-min))
(keep-lines
- (regexp-opt (append refs (list id subject)))))))
+ (regexp-opt ',(append refs (list id subject)))))))
(gnus-fetch-headers (list last) (if (numberp limit)
(* 2 limit) limit) t)))))
(when (listp new-headers)
(defun gnus-summary-insert-new-articles ()
"Insert all new articles in this group."
(interactive)
- (prog1
- (let ((old (sort (mapcar 'car gnus-newsgroup-data) '<))
- (old-high gnus-newsgroup-highest)
- (nnmail-fetched-sources (list t))
- i new)
- (setq gnus-newsgroup-active
- (gnus-copy-sequence
- (gnus-activate-group gnus-newsgroup-name 'scan)))
- (setq i (cdr gnus-newsgroup-active)
- gnus-newsgroup-highest i)
- (while (> i old-high)
- (push i new)
- (decf i))
- (if (not new)
- (message "No gnus is bad news")
- (gnus-summary-insert-articles new)
- (setq gnus-newsgroup-unreads
- (gnus-sorted-nunion gnus-newsgroup-unreads new))
- (gnus-summary-limit (gnus-sorted-nunion old new))))
- (gnus-summary-position-point)))
+ (let ((old (sort (mapcar 'car gnus-newsgroup-data) '<))
+ (old-high gnus-newsgroup-highest)
+ (nnmail-fetched-sources (list t))
+ (new-active (gnus-activate-group gnus-newsgroup-name 'scan))
+ i new)
+ (unless new-active
+ (error "Couldn't fetch new data"))
+ (setq gnus-newsgroup-active (gnus-copy-sequence new-active))
+ (setq i (cdr gnus-newsgroup-active)
+ gnus-newsgroup-highest i)
+ (while (> i old-high)
+ (push i new)
+ (decf i))
+ (if (not new)
+ (message "No gnus is bad news")
+ (gnus-summary-insert-articles new)
+ (setq gnus-newsgroup-unreads
+ (gnus-sorted-nunion gnus-newsgroup-unreads new))
+ (gnus-summary-limit (gnus-sorted-nunion old new))))
+ (gnus-summary-position-point))
;;; Bookmark support for Gnus.
(declare-function bookmark-make-record-default
(error
(gmm-write-region (point-min) (point-max) tmpfile nil 'no-message nil
'excl)
- (unix-sync))) ;; no fsync :(
+ (when (fboundp 'unix-sync)
+ (unix-sync)))) ;; no fsync :(
(nnheader-cancel-timer 24h)
(condition-case err
(add-name-to-file tmpfile curfile)
(when (numberp article)
(let* ((data-header (or prepared-data-header
(spam-fetch-article-header article))))
- (if (arrayp data-header)
- (cond
- ((equal field 'number)
- (mail-header-number data-header))
- ((equal field 'from)
- (mail-header-from data-header))
- ((equal field 'message-id)
- (mail-header-message-id data-header))
- ((equal field 'subject)
- (mail-header-subject data-header))
- ((equal field 'references)
- (mail-header-references data-header))
- ((equal field 'date)
- (mail-header-date data-header))
- ((equal field 'xref)
- (mail-header-xref data-header))
- ((equal field 'extra)
- (mail-header-extra data-header))
- (t
- (gnus-error
- 5
- "spam-fetch-field-fast: unknown field %s requested"
- field)
- nil))
- (gnus-message 6 "Article %d has a nil data header" article)))))
+ (cond
+ ((not (arrayp data-header))
+ (gnus-message 6 "Article %d has a nil data header" article))
+ ((equal field 'number)
+ (mail-header-number data-header))
+ ((equal field 'from)
+ (mail-header-from data-header))
+ ((equal field 'message-id)
+ (mail-header-message-id data-header))
+ ((equal field 'subject)
+ (mail-header-subject data-header))
+ ((equal field 'references)
+ (mail-header-references data-header))
+ ((equal field 'date)
+ (mail-header-date data-header))
+ ((equal field 'xref)
+ (mail-header-xref data-header))
+ ((equal field 'extra)
+ (mail-header-extra data-header))
+ (t
+ (gnus-error
+ 5
+ "spam-fetch-field-fast: unknown field %s requested"
+ field)
+ nil)))))
(defun spam-fetch-field-from-fast (article &optional prepared-data-header)
(spam-fetch-field-fast article 'from prepared-data-header))