summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortheimpostor <theimpostor@users.noreply.github.com>2024-07-28 21:45:11 -0500
committerGitHub <noreply@github.com>2024-07-28 21:45:11 -0500
commit710a391fc3de6c3e246750b6b6dfc07811d1afcc (patch)
treed8cfe17d0259ae5452bb3562b1ec0faace85ea75
parent3a803e94cfa813861d4f8ca2257d934892045614 (diff)
parente64e9d6422e0404c15a1544676c38ddb08e7a7ed (diff)
Merge pull request #9 from jrmd54/fix_kitty_empty_paste
Fixed hangout when pasting empty string with kitty
-rw-r--r--main.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/main.go b/main.go
index c698a8d..d25666e 100644
--- a/main.go
+++ b/main.go
@@ -199,7 +199,7 @@ func paste() error {
}
buf = append(buf, b)
// Skip initial 7 bytes of response
- if len(buf) > 9 && buf[len(buf)-2] == '\x1b' && buf[len(buf)-1] == '\\' {
+ if len(buf) >= 9 && buf[len(buf)-2] == '\x1b' && buf[len(buf)-1] == '\\' {
buf = buf[:len(buf)-2]
break
}