summaryrefslogtreecommitdiffstats
path: root/sys/isa
diff options
context:
space:
mode:
authorbde <bde@FreeBSD.org>1995-04-01 19:57:36 +0000
committerbde <bde@FreeBSD.org>1995-04-01 19:57:36 +0000
commit23411ef52ee7dcff7a9a290530675b19287ac8ae (patch)
tree348527ad4e67163039a1d1c5b125bba184dd186b /sys/isa
parent6f307fa4969845b9cf410a96812226f30224442e (diff)
downloadFreeBSD-src-23411ef52ee7dcff7a9a290530675b19287ac8ae.zip
FreeBSD-src-23411ef52ee7dcff7a9a290530675b19287ac8ae.tar.gz
Fix count in mark_for_update() for insert-char(s) and delete-char(s).
Everything from the cursor to the end of the line must be updated. Fix comment about erase-char(s).
Diffstat (limited to 'sys/isa')
-rw-r--r--sys/isa/syscons.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/isa/syscons.c b/sys/isa/syscons.c
index 072f6a3..6ded8a5 100644
--- a/sys/isa/syscons.c
+++ b/sys/isa/syscons.c
@@ -25,7 +25,7 @@
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
- * $Id: syscons.c,v 1.107 1995/03/03 08:37:07 sos Exp $
+ * $Id: syscons.c,v 1.109 1995/03/30 14:32:29 sos Exp $
*/
#include "sc.h"
@@ -1528,7 +1528,7 @@ scan_esc(scr_stat *scp, u_char c)
src = dst + count;
fillw(scp->term.cur_attr | scr_map[0x20], src, n);
mark_for_update(scp, scp->cursor_pos - scp->scr_buf);
- mark_for_update(scp, scp->cursor_pos - scp->scr_buf + n);
+ mark_for_update(scp, scp->cursor_pos - scp->scr_buf + count + n);
break;
case '@': /* Insert n chars */
@@ -1541,7 +1541,7 @@ scan_esc(scr_stat *scp, u_char c)
bcopyw(src, dst, count * sizeof(u_short));
fillw(scp->term.cur_attr | scr_map[0x20], src, n);
mark_for_update(scp, scp->cursor_pos - scp->scr_buf);
- mark_for_update(scp, scp->cursor_pos - scp->scr_buf + count);
+ mark_for_update(scp, scp->cursor_pos - scp->scr_buf + count + n);
break;
case 'S': /* scroll up n lines */
@@ -1570,7 +1570,7 @@ scan_esc(scr_stat *scp, u_char c)
mark_all(scp);
break;
- case 'X': /* delete n characters in line */
+ case 'X': /* erase n characters in line */
n = scp->term.param[0]; if (n < 1) n = 1;
if (n > scp->xsize - scp->xpos)
n = scp->xsize - scp->xpos;
OpenPOWER on IntegriCloud