Subject: bug#53501: 29.0.50; Column widening widens multiple columns in *Process List*

From: Lars Ingebrigtsen <[email-masked]>
Date: Tue, 25 Jan 2022 14:15:56 +0100

Thuna <[email-masked]> writes:

> In the *Porcess List* buffer, if tabulated-list-widen-column is called
> on the second or the third column, both columns end up widening.  The
> same thing happens in columns 5 and 6 as well (although it is currently
> bugged due to bug#53498).
>
> This can be replicated as follows:
> 0. emacs -Q
> 1. M-x shell
> 2. M-x list-processes
> 3. C-x o
> 4. M-f M-f
> 5. }
>
> It is possible that this is not a bug in process itself but I have seen
> nothing else that could be the problem.

Hm, very odd.  I wondered whether it was somehow increasing the widths
of two columns, but:

(cl-incf (cadr (aref tabulated-list-format 1)))
(tabulated-list-print t)

demonstrates this problem.

It seems like tabulated-list-print is itself increasing the width of the
subsequent column?  Hm, yes.  No!  It's a matter of a shared list?

[("Process" 15 . #1=(t)) ("PID" . #2=(10 . #1#)) ("Status" . #2#) ("Buffer" 26 . #1#) ("TTY" . #3=(11 . #1#)) ("Thread" . #3#) ("Command" 0 . #1#)]

Yes, PID and Status share lists.

Right, the problem is that process-menu-mode uses a constant here, and
tabulated-list-mode mutates that, and that's undefined.  Now fixed in
Emacs 29.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no