Skip to content

Commit

Permalink
all: correct typos in comments
Browse files Browse the repository at this point in the history
Change-Id: Idc75240e5546be2f2b091878910339b4967c93c7
GitHub-Last-Rev: c78560c
GitHub-Pull-Request: #166
Reviewed-on: https://go-review.googlesource.com/c/net/+/465715
Run-TryBot: Ian Lance Taylor <[email protected]>
Reviewed-by: David Chase <[email protected]>
Reviewed-by: Ian Lance Taylor <[email protected]>
Auto-Submit: Ian Lance Taylor <[email protected]>
TryBot-Result: Gopher Robot <[email protected]>
  • Loading branch information
alexandear authored and gopherbot committed Feb 7, 2023
1 parent 296f09a commit 7e3c19c
Show file tree
Hide file tree
Showing 9 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion http2/server_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1704,7 +1704,7 @@ func TestServer_Rejects_HeadersSelfDependence(t *testing.T) {
})
}

// No PRIORTY frame with a self-dependence.
// No PRIORITY frame with a self-dependence.
func TestServer_Rejects_PrioritySelfDependence(t *testing.T) {
testServerRejectsStream(t, ErrCodeProtocol, func(st *serverTester) {
st.fr.AllowIllegalWrites = true
Expand Down
2 changes: 1 addition & 1 deletion icmp/multipart.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ func multipartMessageBodyDataLen(proto int, withOrigDgram bool, b []byte, exts [
}

// multipartMessageOrigDatagramLen takes b as an original datagram,
// and returns a required length for a padded orignal datagram in wire
// and returns a required length for a padded original datagram in wire
// format.
func multipartMessageOrigDatagramLen(proto int, b []byte) int {
roundup := func(b []byte, align int) int {
Expand Down
6 changes: 3 additions & 3 deletions internal/sockstest/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ func MarshalAuthReply(ver int, m socks.AuthMethod) ([]byte, error) {
return []byte{byte(ver), byte(m)}, nil
}

// A CmdRequest repesents a command request.
// A CmdRequest represents a command request.
type CmdRequest struct {
Version int
Cmd socks.Command
Expand Down Expand Up @@ -120,12 +120,12 @@ func MarshalCmdReply(ver int, reply socks.Reply, a *socks.Addr) ([]byte, error)
return b, nil
}

// A Server repesents a server for handshake testing.
// A Server represents a server for handshake testing.
type Server struct {
ln net.Listener
}

// Addr rerurns a server address.
// Addr returns a server address.
func (s *Server) Addr() net.Addr {
return s.ln.Addr()
}
Expand Down
2 changes: 1 addition & 1 deletion ipv4/multicastlistener_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ func TestUDPPerInterfaceSinglePacketConnWithSingleGroupListener(t *testing.T) {
}
c, err := net.ListenPacket("udp4", net.JoinHostPort(ip.String(), port)) // unicast address with non-reusable port
if err != nil {
// The listen may fail when the serivce is
// The listen may fail when the service is
// already in use, but it's fine because the
// purpose of this is not to test the
// bookkeeping of IP control block inside the
Expand Down
2 changes: 1 addition & 1 deletion ipv6/dgramopt.go
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ func (c *dgramOpt) Checksum() (on bool, offset int, err error) {
return true, offset, nil
}

// SetChecksum enables the kernel checksum processing. If on is ture,
// SetChecksum enables the kernel checksum processing. If on is true,
// the offset should be an offset in bytes into the data of where the
// checksum field is located.
func (c *dgramOpt) SetChecksum(on bool, offset int) error {
Expand Down
2 changes: 1 addition & 1 deletion ipv6/multicastlistener_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ func TestUDPPerInterfaceSinglePacketConnWithSingleGroupListener(t *testing.T) {
}
c, err := net.ListenPacket("udp6", net.JoinHostPort(ip.String()+"%"+ifi.Name, port)) // unicast address with non-reusable port
if err != nil {
// The listen may fail when the serivce is
// The listen may fail when the service is
// already in use, but it's fine because the
// purpose of this is not to test the
// bookkeeping of IP control block inside the
Expand Down
2 changes: 1 addition & 1 deletion netutil/listen.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ type limitListener struct {
}

// acquire acquires the limiting semaphore. Returns true if successfully
// accquired, false if the listener is closed and the semaphore is not
// acquired, false if the listener is closed and the semaphore is not
// acquired.
func (l *limitListener) acquire() bool {
select {
Expand Down
2 changes: 1 addition & 1 deletion webdav/webdav.go
Original file line number Diff line number Diff line change
Expand Up @@ -655,7 +655,7 @@ func handlePropfindError(err error, info os.FileInfo) error {
// We need to be careful with other errors: there is no way to abort the xml stream
// part way through while returning a valid PROPFIND response. Returning only half
// the data would be misleading, but so would be returning results tainted by errors.
// The curent behaviour by returning an error here leads to the stream being aborted,
// The current behaviour by returning an error here leads to the stream being aborted,
// and the parent http server complaining about writing a spurious header. We should
// consider further enhancing this error handling to more gracefully fail, or perhaps
// buffer the entire response until we've walked the tree.
Expand Down
2 changes: 1 addition & 1 deletion websocket/hybi.go
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,7 @@ func generateNonce() (nonce []byte) {
return
}

// removeZone removes IPv6 zone identifer from host.
// removeZone removes IPv6 zone identifier from host.
// E.g., "[fe80::1%en0]:8080" to "[fe80::1]:8080"
func removeZone(host string) string {
if !strings.HasPrefix(host, "[") {
Expand Down

0 comments on commit 7e3c19c

Please sign in to comment.