fix bugs in DynamicVectorDecoder