[libvirt] [PATCH for 1.2.7 3/8] virsh: expose virConnectGetDomainCapabilities
Daniel P. Berrange
berrange at redhat.com
Wed Jul 2 14:47:57 UTC 2014
On Mon, Jun 30, 2014 at 05:31:46PM +0200, Michal Privoznik wrote:
> The API is exposed under 'domcapabilities' command. Currently, with
> the variety of drivers that libvirt supports, none of the command
> arguments is obligatory, but all are optional instead.
>
> Signed-off-by: Michal Privoznik <mprivozn at redhat.com>
> ---
> tools/virsh-host.c | 84 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
> tools/virsh.pod | 16 +++++++++++
> 2 files changed, 100 insertions(+)
ACK
> +static bool
> +cmdDomCapabilities(vshControl *ctl, const vshCmd *cmd)
> +{
> + bool ret = false;
> + char *caps;
> + const char *virttype = NULL;
> + const char *emulatorbin = NULL;
> + const char *arch = NULL;
> + const char *machine = NULL;
> + const unsigned int flags = 0; /* No flags so far */
> +
> + if (vshCommandOptString(cmd, "virttype", &virttype) < 0) {
> + vshError(ctl, "%s", _("ble"));
I imagine "ble" was a placeholder you meant to replace :-)
> + goto cleanup;
> + }
> +
> + if (vshCommandOptString(cmd, "emulatorbin", &emulatorbin) < 0) {
> + vshError(ctl, "%s", _("ble"));
> + goto cleanup;
> + }
> +
> + if (vshCommandOptString(cmd, "arch", &arch) < 0) {
> + vshError(ctl, "%s", _("ble"));
> + goto cleanup;
> + }
> +
> + if (vshCommandOptString(cmd, "machine", &machine) < 0) {
> + vshError(ctl, "%s", _("ble"));
> + goto cleanup;
> + }
ACK if that is fixed.
Regards,
Daniel
--
|: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org -o- http://virt-manager.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|
More information about the libvir-list
mailing list