diff --git a/helpers_unix.go b/helpers_unix.go index 42db1bb..5034992 100644 --- a/helpers_unix.go +++ b/helpers_unix.go @@ -4,12 +4,11 @@ package termtest import ( - "bytes" "errors" ) var ERR_ACCESS_DENIED = errors.New("only used on windows, this should never match") -func cleanPtySnapshot(b []byte, _ bool) []byte { - return bytes.TrimRight(b, "\x00") +func cleanPtySnapshot(b []byte, cursorPos int, _ bool) ([]byte, int) { + return b, cursorPos }