[libvirt RFC 01/24] qemu_block: extract block commit code to separate function