From 28f23f18e9d79405a60348c4f7aeded33da9135b Mon Sep 17 00:00:00 2001 From: nicm Date: Fri, 25 Sep 2015 15:53:07 +0000 Subject: Free the history when it is cleared, based on a diff from Carlo Cannas. --- cmd-clear-history.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'cmd-clear-history.c') diff --git a/cmd-clear-history.c b/cmd-clear-history.c index 88dbbcf7..63e9d548 100644 --- a/cmd-clear-history.c +++ b/cmd-clear-history.c @@ -47,9 +47,7 @@ cmd_clear_history_exec(struct cmd *self, struct cmd_q *cmdq) if (wp->mode == &window_copy_mode) window_pane_reset_mode(wp); - - grid_move_lines(gd, 0, gd->hsize, gd->sy); - gd->hsize = 0; + grid_clear_history(gd); return (CMD_RETURN_NORMAL); } -- cgit