]> git.eshelyaron.com Git - emacs.git/commitdiff
mail-source.el (mail-source-fetch): Don't message if we're fetching mail from a file...
authorLars Magne Ingebrigtsen <larsi@gnus.org>
Sun, 5 Sep 2010 23:38:33 +0000 (23:38 +0000)
committerKatsumi Yamaoka <yamaoka@jpl.org>
Sun, 5 Sep 2010 23:38:33 +0000 (23:38 +0000)
lisp/gnus/ChangeLog
lisp/gnus/mail-source.el

index bc814ee3a92c86f21e5a419f79f215449ba3ec5d..24a5c8dee4ecc15fb02cb08628b68da8096dbc09 100644 (file)
@@ -1,5 +1,8 @@
 2010-09-05  Lars Magne Ingebrigtsen  <larsi@gnus.org>
 
+       * mail-source.el (mail-source-fetch): Don't message if we're fetching
+       mail from a file, and the file doesn't exist.
+
        * pop3.el (pop3-streaming-movemail): Return t for success.
 
        * nnimap.el (nnimap-open-connection): Look for the "imaps" entry in the
index 7a626869347cd5eb790716e5a0a176395916cbe2..d3ceb6dfd07d3f59caec857fdd123a52d72689ab 100644 (file)
@@ -544,11 +544,16 @@ Return the number of files that were found."
   (mail-source-bind-common source
     (if (or mail-source-plugged plugged)
        (save-excursion
-         (nnheader-message 4 "%sReading incoming mail from %s..."
-                           (if method
-                               (format "%s: " method)
-                             "")
-                           (car source))
+         ;; Special-case the `file' handler since it's so common and
+         ;; just adds noise.
+         (when (or (not (eq (car source) 'file))
+                   (mail-source-bind (file source)
+                     (file-exists-p path)))
+           (nnheader-message 4 "%sReading incoming mail from %s..."
+                             (if method
+                                 (format "%s: " method)
+                               "")
+                             (car source)))
          (let ((function (cadr (assq (car source) mail-source-fetcher-alist)))
                (found 0))
            (unless function