summaryrefslogtreecommitdiff
path: root/lisp/mail/emacsbug.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/mail/emacsbug.el')
-rw-r--r--lisp/mail/emacsbug.el9
1 files changed, 5 insertions, 4 deletions
diff --git a/lisp/mail/emacsbug.el b/lisp/mail/emacsbug.el
index babfd2e68ae..ad6f1b7a58b 100644
--- a/lisp/mail/emacsbug.el
+++ b/lisp/mail/emacsbug.el
@@ -543,10 +543,11 @@ Message buffer where you can explain more about the patch."
(with-temp-buffer
(insert-file-contents file)
(while (search-forward-regexp "^\\+\\{3\\} ./\\(.*\\)" nil t)
- (push (expand-file-name
- (match-string-no-properties 1)
- source-directory)
- files)))
+ (let ((file (expand-file-name
+ (match-string-no-properties 1)
+ source-directory)))
+ (when (file-readable-p file)
+ (push file files)))))
(mapcan
(lambda (patch)
(seq-remove