We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 59b1bcc + b916fde commit f3dc1feCopy full SHA for f3dc1fe
query.go
@@ -36,16 +36,18 @@ func (c *Client) cancelQuery() error {
36
Buf: make([]byte, 1),
37
}
38
proto.ClientCodeCancel.Encode(&b)
39
+
40
+ var retErr error
41
if err := c.flushBuf(ctx, &b); err != nil {
- return errors.Wrap(err, "flush")
42
+ retErr = errors.Join(retErr, errors.Wrap(err, "flush"))
43
44
- // Closing connection to prevent further queries.
45
+ // Always close connection to prevent further queries.
46
if err := c.Close(); err != nil {
- return errors.Wrap(err, "close")
47
+ retErr = errors.Join(retErr, errors.Wrap(err, "close"))
48
49
- return nil
50
+ return retErr
51
52
53
func (c *Client) querySettings(q Query) []proto.Setting {
0 commit comments