On Fri, Apr 13, 2018 at 01:15:12PM +0200, Katerina Koukiou wrote:
Signed-off-by: Katerina Koukiou <kkoukiou(a)redhat.com>
---
data/org.libvirt.Domain.xml | 5 +++--
src/domain.c | 22 +++++++++++++++++++++-
test/test_domain.py | 7 +++++++
3 files changed, 31 insertions(+), 3 deletions(-)
[...]
+static void
+virtDBusDomainSetAutostart(GVariant *value,
+ const gchar *objectPath,
+ gpointer userData,
+ GError **error)
+{
+ virtDBusConnect *connect = userData;
+ g_autoptr(virDomain) domain = NULL;
+ gboolean autostart;
+
+ g_variant_get(value, "b", &autostart);
+
+ domain = virtDBusDomainGetVirDomain(connect, objectPath, error);
+ if (!domain)
+ return;
+
+ if (virDomainSetAutostart(domain, autostart) < 0)
+ return virtDBusUtilSetLastVirtError(error);
You missed one 'return'.
Pavel