snapshot: fix referencing wrong variable in while loop in do_delvm