From 7059ca9b15b3920f1d803d626e57adfacb6bd55c Mon Sep 17 00:00:00 2001 From: AnotherTest Date: Thu, 7 Jan 2021 00:28:12 +0330 Subject: [PATCH] LibLine: Don't clear the displayed buffer when interrupted Since we always restart on a new line, there's no reason to clear the previous lines. --- Libraries/LibLine/Editor.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Libraries/LibLine/Editor.cpp b/Libraries/LibLine/Editor.cpp index f463a30d2d6..470557e44b6 100644 --- a/Libraries/LibLine/Editor.cpp +++ b/Libraries/LibLine/Editor.cpp @@ -480,8 +480,7 @@ void Editor::interrupted() m_finish = false; reposition_cursor(true); if (m_suggestion_display->cleanup()) - reposition_cursor(); - cleanup(); + reposition_cursor(true); fprintf(stderr, "\n"); fflush(stderr); m_buffer.clear();