@@ -834,8 +834,8 @@ void guac_terminal_scroll_up(guac_terminal* term,
834834 /* Scroll up visibly */
835835 guac_terminal_display_copy_rows (term -> display , start_row + amount , end_row , - amount );
836836
837- /* Advance by scroll amount */
838- guac_terminal_buffer_scroll_up (term -> current_buffer , amount );
837+ /* Advance and increase buffer length by scroll amount */
838+ guac_terminal_buffer_scroll_up (term -> current_buffer , amount , true );
839839
840840 /* Reset scrollbar bounds */
841841 guac_terminal_scrollbar_set_bounds (term -> scrollbar ,
@@ -1225,7 +1225,7 @@ static void __guac_terminal_resize(guac_terminal* term, int width, int height) {
12251225 shift_amount , term -> display -> height - 1 , - shift_amount );
12261226
12271227 /* Update buffer top and cursor row based on shift */
1228- guac_terminal_buffer_scroll_up (term -> current_buffer , shift_amount );
1228+ guac_terminal_buffer_scroll_up (term -> current_buffer , shift_amount , false );
12291229 term -> cursor_row -= shift_amount ;
12301230 if (term -> visible_cursor_row != -1 )
12311231 term -> visible_cursor_row -= shift_amount ;
@@ -1296,6 +1296,10 @@ static void __guac_terminal_resize(guac_terminal* term, int width, int height) {
12961296 /* Draw characters at top from scroll */
12971297 __guac_terminal_redraw_rect (term , 0 , 0 , shift_amount - 1 , width - 1 );
12981298
1299+ /* Draw characters from scroll at bottom */
1300+ __guac_terminal_redraw_rect (term , term -> display -> height - shift_amount ,
1301+ 0 , term -> display -> height - 1 , width - 1 );
1302+
12991303 }
13001304
13011305 }
0 commit comments