From 90ce2b80342299ef4c6c2f6b08cca55e20ffa06b Mon Sep 17 00:00:00 2001 From: Lars Ingebrigtsen Date: Fri, 29 Jan 2021 08:34:43 +0100 Subject: [PATCH] rmail-summary-mark-deleted optional argument fix * lisp/mail/rmailsum.el (rmail-summary-mark-deleted): Argument N is optional, so don't assume that it's a number (bug#39076). --- lisp/mail/rmailsum.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lisp/mail/rmailsum.el b/lisp/mail/rmailsum.el index d29115a9570..7f99ecdcf2c 100644 --- a/lisp/mail/rmailsum.el +++ b/lisp/mail/rmailsum.el @@ -974,8 +974,9 @@ a negative argument means to delete and move forward." (delete-char 1) (insert "D")) ;; Discard cached new summary line. - (with-current-buffer rmail-buffer - (aset rmail-summary-vector (1- n) nil)))) + (when n + (with-current-buffer rmail-buffer + (aset rmail-summary-vector (1- n) nil))))) (beginning-of-line)) (defun rmail-summary-update-line (n) -- 2.39.2