fix bugs in dynamicVector compression