summaryrefslogtreecommitdiff
path: root/lib/console.tcl
diff options
context:
space:
mode:
Diffstat (limited to 'lib/console.tcl')
-rw-r--r--lib/console.tcl2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/console.tcl b/lib/console.tcl
index 2075374683..5597188d80 100644
--- a/lib/console.tcl
+++ b/lib/console.tcl
@@ -120,7 +120,7 @@ method _read {fd after} {
} else {
$w_t delete $console_cr end
$w_t insert end "\n"
- $w_t insert end [string range $buf $c $cr]
+ $w_t insert end [string range $buf $c [expr {$cr - 1}]]
set c $cr
incr c
}