Skip to content

Commit 13bae83

Browse files
authored
docs: fix comment typos (#38)
1 parent 51acb8b commit 13bae83

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

conn_test.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ func (a fakeAddr) String() string {
4747
return "str"
4848
}
4949

50-
// newTestConn creates a connnection backed by a fake network connection using
50+
// newTestConn creates a connection backed by a fake network connection using
5151
// default values for buffering.
5252
func newTestConn(r io.Reader, w io.Writer, isServer bool) *Conn {
5353
return newConn(fakeNetConn{Reader: r, Writer: w}, isServer, 1024, 1024, nil, nil, nil)
@@ -149,7 +149,7 @@ func TestFraming(t *testing.T) {
149149
}
150150

151151
func TestControl(t *testing.T) {
152-
const message = "this is a ping/pong messsage"
152+
const message = "this is a ping/pong message"
153153
for _, isServer := range []bool{true, false} {
154154
for _, isWriteControl := range []bool{true, false} {
155155
name := fmt.Sprintf("s:%v, wc:%v", isServer, isWriteControl)
@@ -440,7 +440,7 @@ func TestWriteAfterMessageWriterClose(t *testing.T) {
440440
w, _ := wc.NextWriter(BinaryMessage)
441441
io.WriteString(w, "hello")
442442
if err := w.Close(); err != nil {
443-
t.Fatalf("unxpected error closing message writer, %v", err)
443+
t.Fatalf("unexpected error closing message writer, %v", err)
444444
}
445445

446446
if _, err := io.WriteString(w, "world"); err == nil {

proxy.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ func (hpd *httpProxyDialer) Dial(network string, addr string) (net.Conn, error)
5959
return nil, err
6060
}
6161

62-
// Read response. It's OK to use and discard buffered reader here becaue
62+
// Read response. It's OK to use and discard buffered reader here because
6363
// the remote server does not speak until spoken to.
6464
br := bufio.NewReader(conn)
6565
resp, err := http.ReadResponse(br, connectReq)

0 commit comments

Comments
 (0)