leverage local buffer

pull/215/head
v2ray 2016-07-17 12:59:57 +02:00
parent 7e499ee0b6
commit 1931820c4c
No known key found for this signature in database
GPG Key ID: 7251FFA14BB18169
1 changed files with 1 additions and 1 deletions

View File

@ -36,7 +36,7 @@ func (this *BufferedSegmentWriter) Write(seg Segment) {
}
if this.buffer == nil {
this.buffer = alloc.NewSmallBuffer().Clear()
this.buffer = alloc.NewLocalBuffer(2048).Clear()
}
this.buffer.Value = seg.Bytes(this.buffer.Value)