mirror of
https://github.com/tmux/tmux.git
synced 2026-03-31 16:56:28 +00:00
When history-limit is changed, apply to existing panes, not just new
ones. GitHub issue 4705.
This commit is contained in:
7
grid.c
7
grid.c
@@ -375,14 +375,17 @@ grid_trim_history(struct grid *gd, u_int ny)
|
||||
* and shift up.
|
||||
*/
|
||||
void
|
||||
grid_collect_history(struct grid *gd)
|
||||
grid_collect_history(struct grid *gd, int all)
|
||||
{
|
||||
u_int ny;
|
||||
|
||||
if (gd->hsize == 0 || gd->hsize < gd->hlimit)
|
||||
return;
|
||||
|
||||
ny = gd->hlimit / 10;
|
||||
if (all)
|
||||
ny = gd->hsize - gd->hlimit;
|
||||
else
|
||||
ny = gd->hlimit / 10;
|
||||
if (ny < 1)
|
||||
ny = 1;
|
||||
if (ny > gd->hsize)
|
||||
|
||||
Reference in New Issue
Block a user