1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2024-06-24 08:25:23 +00:00

release buffer in error case

This commit is contained in:
Darien Raymond 2019-02-20 22:55:57 +01:00
parent da8efb4afe
commit 8d09d74224
No known key found for this signature in database
GPG Key ID: 7251FFA14BB18169

View File

@ -117,6 +117,7 @@ func (c *connection) Write(b []byte) (int, error) {
func (c *connection) WriteMultiBuffer(mb buf.MultiBuffer) error {
if c.done.Done() {
buf.ReleaseMulti(mb)
return io.ErrClosedPipe
}