Browse code

Redraw on signals

John Hawthorn authored on 15/09/2018 21:20:29
Showing 1 changed files

... ...
@@ -366,6 +366,11 @@ int tty_interface_run(tty_interface_t *state) {
366 366
 
367 367
 	for (;;) {
368 368
 		do {
369
+			while(!tty_input_ready(state->tty, -1, 1)) {
370
+				/* We received a signal (probably WINCH) */
371
+				draw(state);
372
+			}
373
+
369 374
 			char s[2] = {tty_getchar(state->tty), '\0'};
370 375
 			handle_input(state, s, 0);
371 376