remove illegal varErase, add keynodes, fixed bugs in find min path