virDomain{Attach,Detach}Device is only permitted on active domains. Explicitly state this restriction in the API documentation. --- src/libvirt.c | 6 ++++-- 1 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/libvirt.c b/src/libvirt.c index 05e45f3..918dd4f 100644 --- a/src/libvirt.c +++ b/src/libvirt.c @@ -4919,7 +4919,8 @@ error: * @domain: pointer to domain object * @xml: pointer to XML description of one device * - * Create a virtual device attachment to backend. + * Create a virtual device attachment to backend. This function, having + * hotplug semantics, is only allowed on an active domain. * * Returns 0 in case of success, -1 in case of failure. */ @@ -4962,7 +4963,8 @@ error: * @domain: pointer to domain object * @xml: pointer to XML description of one device * - * Destroy a virtual device attachment to backend. + * Destroy a virtual device attachment to backend. This function, having + * hot-unplug semantics, is only allowed on an active domain. * * Returns 0 in case of success, -1 in case of failure. */ -- 1.6.0.2 -- Libvir-list mailing list Libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list