Skip to content

Commit 1c4be3d

Browse files
committed
Comment out newline replacements
As suggested by gliderlabs#129 to fix side-by-side splits in screen/tmux
1 parent c9fc441 commit 1c4be3d

File tree

3 files changed

+4
-5
lines changed

3 files changed

+4
-5
lines changed

example_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import (
44
"io"
55
"io/ioutil"
66

7-
"github.com/gliderlabs/ssh"
7+
"github.com/tweag/gliderlabs-ssh"
88
)
99

1010
func ExampleListenAndServe() {

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
module github.com/gliderlabs/ssh
1+
module github.com/tweag/gliderlabs-ssh
22

33
go 1.12
44

session.go

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
package ssh
22

33
import (
4-
"bytes"
54
"context"
65
"errors"
76
"fmt"
@@ -133,8 +132,8 @@ func (sess *session) Write(p []byte) (n int, err error) {
133132
m := len(p)
134133
// normalize \n to \r\n when pty is accepted.
135134
// this is a hardcoded shortcut since we don't support terminal modes.
136-
p = bytes.Replace(p, []byte{'\n'}, []byte{'\r', '\n'}, -1)
137-
p = bytes.Replace(p, []byte{'\r', '\r', '\n'}, []byte{'\r', '\n'}, -1)
135+
// p = bytes.Replace(p, []byte{'\n'}, []byte{'\r', '\n'}, -1)
136+
// p = bytes.Replace(p, []byte{'\r', '\r', '\n'}, []byte{'\r', '\n'}, -1)
138137
n, err = sess.Channel.Write(p)
139138
if n > m {
140139
n = m

0 commit comments

Comments
 (0)