if (tstLine != 0) {
if (ntstLine != 0) { tstLine = ntstLine;
static int ClrBottom(int total){static	chtype	*tstLine;static	size_t	lenLine;int	row, col;int	top    = total;int	last   = min(screen_columns, newscr->_maxx+1);size_t	length = sizeof(chtype) * last;chtype	blank  = newscr->_line[total-1].text[last-1]; /* lower right char */	if(!clr_eos || !can_clear_with(blank))		return total;	if (tstLine == 0)		tstLine = (chtype *)malloc(length);	else if (length > lenLine)		tstLine = (chtype *)realloc(tstLine, length);	if (tstLine != 0) {		lenLine = length;		for (col = 0; col < last; col++)			tstLine[col] = blank;		for (row = total-1; row >= 0; row--) {			if (memcmp(tstLine, newscr->_line[row].text, length))				break;			if (memcmp(tstLine, curscr->_line[row].text, length))				top = row;		}		/* don't use clr_eos for just one line if clr_eol available */		if (top < total-1 || (top < total && !clr_eol && !clr_bol)) {			GoTo(top,0);			ClrToEOS(blank);			total = top;		}	}#if NO_LEAKS	if (tstLine != 0)		FreeAndNull(tstLine);#endif	return total;}