From b01f7a186ebe79542d9b9645c09cb08ddfb01fbb Mon Sep 17 00:00:00 2001 From: Filippo Scognamiglio Date: Thu, 6 Nov 2014 02:08:18 +0100 Subject: [PATCH] Prevents deleting the last line when resizing. --- lib/Screen.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Screen.cpp b/lib/Screen.cpp index acc5f81..649756d 100644 --- a/lib/Screen.cpp +++ b/lib/Screen.cpp @@ -307,7 +307,7 @@ void Screen::resizeImage(int new_lines, int new_columns) // create new screen lines and copy from old to new ImageLine* newScreenLines = new ImageLine[new_lines+1]; - for (int i=0; i < qMin(lines-1,new_lines+1) ;i++) + for (int i=0; i < qMin(lines,new_lines+1) ;i++) newScreenLines[i]=screenLines[i]; for (int i=lines;(i > 0) && (i