[libvirt] [PATCHv3 02a/10] qemu: consolidate duplicated monitor migration code