diff options
author | Kay Sievers <kay@vrfy.org> | 2013-11-02 00:01:32 +0100 |
---|---|---|
committer | Kay Sievers <kay@vrfy.org> | 2013-11-02 00:02:56 +0100 |
commit | 98e6c5e62ffcec33bd5255ebaafeafdc5a3f1ada (patch) | |
tree | 3ef2d81dd0c7055e3c6f33ca2271b57ef682c45d /src/core/dbus-manager.c | |
parent | cc27380c1e09bd51380fbeb168d8315cc806e0ab (diff) |
detect_virtualization() returns NULL; pass empty string to dbus
Diffstat (limited to 'src/core/dbus-manager.c')
-rw-r--r-- | src/core/dbus-manager.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/core/dbus-manager.c b/src/core/dbus-manager.c index 46f55d088b..b47fc85101 100644 --- a/src/core/dbus-manager.c +++ b/src/core/dbus-manager.c @@ -466,7 +466,7 @@ static int bus_manager_append_progress(DBusMessageIter *i, const char *property, static int bus_manager_append_virt(DBusMessageIter *i, const char *property, void *data) { Manager *m = data; - const char *id = ""; + const char *id = NULL; assert(i); assert(property); @@ -474,6 +474,8 @@ static int bus_manager_append_virt(DBusMessageIter *i, const char *property, voi detect_virtualization(&id); + if (!id) + id = ""; if (!dbus_message_iter_append_basic(i, DBUS_TYPE_STRING, &id)) return -ENOMEM; |