Skip to content

Commit 2bac920

Browse files
committed
marshaller: fix subtle size-bug
1 parent 168995b commit 2bac920

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

binarymarshaler.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ func (f *Filter) MarshallToWriter(out io.Writer) (int, [sha512.Size384]byte, err
9494
debug("bloomfilter.MarshalBinary: Successfully wrote %d byte(s), sha384 %v",
9595
c.bytes, hash)
9696
}
97-
return c.bytes, hash, err
97+
return c.bytes + len(hashbytes), hash, err
9898
}
9999

100100
// MarshalBinary converts a Filter into []bytes

0 commit comments

Comments
 (0)