From: aaron Date: Sun, 9 Apr 2000 20:21:30 +0000 (+0000) Subject: Put the line-wrap check back under STATE_INIT. It was causing some display X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=2b4859bbbbe1f6218d4cf6ad6ee71f779bdc55f8;p=openbsd Put the line-wrap check back under STATE_INIT. It was causing some display problems in some (curses?) applications, i.e., sniffit. --- diff --git a/sys/arch/i386/isa/pcvt/pcvt_out.c b/sys/arch/i386/isa/pcvt/pcvt_out.c index a0dfa0e8a6c..0b209a9d23f 100644 --- a/sys/arch/i386/isa/pcvt/pcvt_out.c +++ b/sys/arch/i386/isa/pcvt/pcvt_out.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pcvt_out.c,v 1.20 2000/04/02 00:03:11 aaron Exp $ */ +/* $OpenBSD: pcvt_out.c,v 1.21 2000/04/09 20:21:30 aaron Exp $ */ /* * Copyright (c) 1992, 1995 Hellmuth Michaelis and Joerg Wunsch. @@ -352,22 +352,24 @@ sput (u_char *s, U_char kernel, int len, int page) /* char range 0x20...0xff processing depends on current state */ - if (svsp->lastchar && svsp->m_awm && svsp->lastrow == svsp->row) - { - svsp->cur_offset++; - svsp->col = 0; - svsp->lastchar = 0; - if (check_scrollback(svsp)) { - bcopy(svsp->Crtat + svsp->cur_offset - - svsp->maxcol, svsp->Scrollback + - (svsp->scr_offset * svsp->maxcol), - svsp->maxcol * CHR); - } - check_scroll(svsp); - } switch(svsp->state) { case STATE_INIT: + if (svsp->lastchar && svsp->m_awm && + (svsp->lastrow == svsp->row)) + { + svsp->cur_offset++; + svsp->col = 0; + svsp->lastchar = 0; + if (check_scrollback(svsp)) { + bcopy(svsp->Crtat + svsp->cur_offset - + svsp->maxcol, svsp->Scrollback + + (svsp->scr_offset * svsp->maxcol), + svsp->maxcol * CHR); + } + check_scroll(svsp); + } + if(svsp->irm) bcopy((svsp->Crtat + svsp->cur_offset), (svsp->Crtat + svsp->cur_offset) + 1,