浏览代码

Return stream id to the pool in case of a write error.

Harpreet Sawhney 12 年之前
父节点
当前提交
3d65e205b4
共有 1 个文件被更改,包括 1 次插入0 次删除
  1. 1 0
      conn.go

+ 1 - 0
conn.go

@@ -272,6 +272,7 @@ func (c *Conn) exec(op operation, trace Tracer) (interface{}, error) {
 
 	if n, err := c.conn.Write(req); err != nil {
 		c.conn.Close()
+		c.uniq <- id
 		if n > 0 {
 			return nil, ErrProtocol
 		}