net/rpc: Add documentation for client.Close

Fixes #16678

Change-Id: I48c2825d4fef55a75d2f99640a7079c56fce39db
Reviewed-on: https://go-review.googlesource.com/28370
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This commit is contained in:
Sam Whited 2016-09-01 09:19:32 -05:00 committed by Brad Fitzpatrick
parent 6ba5b32922
commit 5df7f5220f

View file

@ -274,6 +274,8 @@ func Dial(network, address string) (*Client, error) {
return NewClient(conn), nil
}
// Close calls the underlying codec's Close method. If the connection is already
// shutting down, ErrShutdown is returned.
func (client *Client) Close() error {
client.mutex.Lock()
if client.closing {