From 0b26a19a4f9088702fdef9b8a2e86b0db2217570 Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Mon, 1 Nov 1993 14:49:04 +0000 Subject: [PATCH] Fix bug in backup inside esc sequence. --- Demo/cwilib/vt100.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Demo/cwilib/vt100.py b/Demo/cwilib/vt100.py index e8023896508..9edd4810b95 100755 --- a/Demo/cwilib/vt100.py +++ b/Demo/cwilib/vt100.py @@ -82,6 +82,8 @@ class VT100: self.fill_top() def send(self, buffer): + self.msg('send: unfinished=%s, buffer=%s', + `self.unfinished`, `buffer`) self.unfinished = self.unfinished + buffer i = 0 n = len(self.unfinished) @@ -110,7 +112,7 @@ class VT100: break argstr = argstr + c else: - i = i - len(argstr) + i = i - len(argstr) - 2 break ## self.msg('found ESC [ %s %s' % (`argstr`, `c`)) args = string.splitfields(argstr, ';')