fixed error in 'advance_volume' procedure
correct error handling in merge_and_compress