Fix a build error on 32 bit go

Change-Id: Iac5894fd8f56da7e420714558a94d63d4fea2d72
This commit is contained in:
Luna 2014-10-29 11:55:21 +01:00 committed by Wouter van Oortmerssen
parent fbcf063401
commit 118abc2871
1 changed files with 1 additions and 1 deletions

View File

@ -152,7 +152,7 @@ func (b *Builder) EndObject() UOffsetT {
// Doubles the size of the byteslice, and copies the old data towards the
// end of the new byteslice (since we build the buffer backwards).
func (b *Builder) growByteBuffer() {
if (len(b.Bytes) & 0xC0000000) != 0 {
if (int64(len(b.Bytes)) & int64(0xC0000000)) != 0 {
panic("cannot grow buffer beyond 2 gigabytes")
}
newSize := len(b.Bytes) * 2