qemu: Split out domain memory saving code to allow reuse
qemu: Split out domain memory saving code to allow reuse

https://bugzilla.redhat.com/show_bug.cgi?id=638512

The code that saves domain memory by migration to file can be reused
while doing external checkpoints of a machine. This patch extracts the
common code and places it in a separate function.
(cherry picked from commit 2771f8b74c1bf50d1fa63bb1c5a01f603215d58f)

mithleshvrts/libvirt-0.10.2,mithleshvrts/libvirt-0.10.2,mithleshvrts/libvirt-0.10.2,mithleshvrts/libvirt-0.10.2,mithleshvrts/libvirt-0.10.2