fixed bug in bitvector serialization