Skip to content

Commit 3e37ebf

Browse files
committed
sshd/terminal: Undo emoji offset bugfix
Introduced another bug: #316
1 parent 5949f97 commit 3e37ebf

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

sshd/terminal/terminal.go

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -537,10 +537,9 @@ func (t *Terminal) handleKey(key rune) (line string, ok bool) {
537537
keyEscape, '[', 'J',
538538
}
539539
t.queue(reset)
540-
// We're still technically on the same line. If we don't offset the
541-
// cursorX, then the fresh prompt could be rendered in the wrong
542-
// position.
543-
t.cursorX += len(reset)
540+
// FIXME: This causes a slice out of bounds panic, but without it we
541+
// get an offset with emojis
542+
// t.cursorX += len(reset)
544543
} else {
545544
// Pushing the line up resets the cursor to 0,0 and we render a
546545
// fresh prompt.

0 commit comments

Comments
 (0)