[libvirt PATCH] util: Improve macOS workaround