emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

master f09ee98: tabulated-list-print delete excess lines


From: Lars Ingebrigtsen
Subject: master f09ee98: tabulated-list-print delete excess lines
Date: Wed, 25 Aug 2021 07:35:24 -0400 (EDT)

branch: master
commit f09ee98e6877a1b8b33bd9ec976d71f1b2d6d2da
Author: Shitikanth Kashyap <shitikanth1@gmail.com>
Commit: Lars Ingebrigtsen <larsi@gnus.org>

    tabulated-list-print delete excess lines
    
    * lisp/emacs-lisp/tabulated-list.el (tabulated-list-print): Ensure
    that we delete remaining lines if the list has gotten shorter
    (bug#50194).
    
    Copyright-paperwork-exempt: yes
---
 lisp/emacs-lisp/tabulated-list.el | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/lisp/emacs-lisp/tabulated-list.el 
b/lisp/emacs-lisp/tabulated-list.el
index f0ee787..fecfa91 100644
--- a/lisp/emacs-lisp/tabulated-list.el
+++ b/lisp/emacs-lisp/tabulated-list.el
@@ -481,6 +481,8 @@ changing `tabulated-list-sort-key'."
               (forward-line 1)
               (delete-region old (point))))))
       (setq entries (cdr entries)))
+    (when update
+      (delete-region (point) (point-max)))
     (set-buffer-modified-p nil)
     ;; If REMEMBER-POS was specified, move to the "old" location.
     (if saved-pt



reply via email to

[Prev in Thread] Current Thread [Next in Thread]