From: Ali Gholami Rudi Date: Wed, 5 Dec 2012 14:42:26 +0000 (+0330) Subject: fbpad: call scr_free() for the correct terminal X-Git-Url: https://repo.or.cz/w/fbpad.git/commitdiff_plain/4e071fbac3dbf4b98f7c1c772a3c67c73cde0243 fbpad: call scr_free() for the correct terminal --- diff --git a/fbpad.c b/fbpad.c index 4032a28..4c6a508 100644 --- a/fbpad.c +++ b/fbpad.c @@ -241,7 +241,7 @@ static int poll_all(void) if (ufds[i].revents & POLLIN) term_read(); if (ufds[i].revents & BADPOLLFLAGS) { - scr_free(&terms[cterm()]); + scr_free(&terms[term_idx[i]]); term_end(); } switch_back(term_idx[i]);