rpc: close handler connections on read error

This commit is contained in:
Darioush Jalali 2024-04-11 12:33:45 -07:00
parent 34aac1d756
commit 8b42a48ad1
No known key found for this signature in database
GPG key ID: 3A24B01A606B0548

View file

@ -652,6 +652,7 @@ func (c *Client) dispatch(codec ServerCodec) {
case err := <-c.readErr:
conn.handler.log.Debug("RPC connection read error", "err", err)
conn.handler.cancelRoot()
conn.close(err, lastOp)
reading = false