]> Sergey Matveev's repositories - btrtrc.git/commitdiff
Count client listener accepts
authorMatt Joiner <anacrolix@gmail.com>
Fri, 21 Jun 2019 04:49:21 +0000 (14:49 +1000)
committerMatt Joiner <anacrolix@gmail.com>
Fri, 21 Jun 2019 04:49:21 +0000 (14:49 +1000)
client.go

index 004ae686e504b6eb657b6e20bfabbe5027477a69..e8dbf0d7519681b09e05bd364f53b6fb0bd6ef93 100644 (file)
--- a/client.go
+++ b/client.go
@@ -419,6 +419,7 @@ func (cl *Client) rejectAccepted(conn net.Conn) bool {
 func (cl *Client) acceptConnections(l net.Listener) {
        for {
                conn, err := l.Accept()
+               torrent.Add("client listener accepts", 1)
                conn = pproffd.WrapNetConn(conn)
                cl.rLock()
                closed := cl.closed.IsSet()