Skip to content

Commit 276b241

Browse files
committed
fix(docs): more verbose method names
1 parent ce2733b commit 276b241

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

ping.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ type Pinger struct {
2222
// only given address, pinging different address would result in error.
2323
//
2424
// To enable receiving packets, Listen() should be called on returned Pinger.
25-
// Close() should be called after Listen() returns if Pinger is no more needed.
25+
// Close() should be called after Listen() returns.
2626
func New(laddr *net.UDPAddr, dst net.IP) (*Pinger, error) {
2727
c, proto, err := newConn(laddr, dst)
2828
if err != nil {
@@ -63,8 +63,8 @@ func (p *Pinger) Close() error {
6363
return p.c.Close()
6464
}
6565

66-
// Listen should be called to start receiving of incomming replies
67-
// and route them into calling Ping* method, so no Ping*() methods should be
66+
// Listen should be called to start receiving of incomming replies and route
67+
// them into calling Pinger.Ping* method, so no Pinger.Ping*() methods should be
6868
// called before Listen and after it returns.
6969
// It is a blocking call, so it should be run as a separate goroutine.
7070
// It returns a non-nil error if context is done or an error occured

0 commit comments

Comments
 (0)