make the snapshot process can exit

make the snapshot process can exit