=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/talk/display.c,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- src/usr.bin/talk/display.c 2001/11/19 19:02:16 1.9 +++ src/usr.bin/talk/display.c 2002/06/20 06:13:56 1.10 @@ -1,4 +1,4 @@ -/* $OpenBSD: display.c,v 1.9 2001/11/19 19:02:16 mpech Exp $ */ +/* $OpenBSD: display.c,v 1.10 2002/06/20 06:13:56 form Exp $ */ /* $NetBSD: display.c,v 1.3 1994/12/09 02:14:13 jtc Exp $ */ /* @@ -38,7 +38,7 @@ #if 0 static char sccsid[] = "@(#)display.c 8.1 (Berkeley) 6/6/93"; #endif -static char rcsid[] = "$OpenBSD: display.c,v 1.9 2001/11/19 19:02:16 mpech Exp $"; +static char rcsid[] = "$OpenBSD: display.c,v 1.10 2002/06/20 06:13:56 form Exp $"; #endif /* not lint */ /* @@ -200,11 +200,10 @@ win->x_col = 0; return; } - win->x_line = (win->x_line + 1) % win->x_nlines; win->x_col = 0; - wmove(win->x_win, win->x_line, win->x_col); - wclrtoeol(win->x_win); - wmove(win->x_win, (win->x_line + 1) % win->x_nlines, win->x_col); - wclrtoeol(win->x_win); + if (++win->x_line == win->x_nlines) { + --win->x_line; + scroll(win->x_win); + } wmove(win->x_win, win->x_line, win->x_col); }