vendor: Update golang.org/cznic/...

This commit is contained in:
Jakob Borg
2016-09-13 21:49:35 +02:00
parent 9bf6917ae8
commit 58cbd19742
31 changed files with 1104 additions and 8369 deletions

View File

@@ -14,6 +14,8 @@ import (
"encoding/binary"
"fmt"
"math"
"github.com/cznic/internal/buffer"
)
func puregoEncode() bool { return true }
@@ -24,7 +26,7 @@ func puregoEncode() bool { return true }
// It is valid to pass a nil buf.
func Encode(buf, src []byte) ([]byte, error) {
if n := MaxEncodedLen(len(src)); len(buf) < n {
buf = make([]byte, n)
buf = *buffer.Get(n)
}
if len(src) > math.MaxInt32 {