chiark / gitweb /
bus: don't include the introspected object in list of subobjects
authorLennart Poettering <lennart@poettering.net>
Tue, 29 Oct 2013 20:37:07 +0000 (21:37 +0100)
committerLennart Poettering <lennart@poettering.net>
Wed, 30 Oct 2013 01:08:57 +0000 (02:08 +0100)
src/libsystemd-bus/bus-introspect.c

index 92deb75dfdcb747ff16c4bcf363226a1c34bf4c9..9a49e431c0a4e124aab47ee453cdb5d9aef5c03f 100644 (file)
@@ -63,7 +63,7 @@ int introspect_write_child_nodes(struct introspect *i, Set *s, const char *prefi
                 const char *e;
 
                 e = object_path_startswith(node, prefix);
                 const char *e;
 
                 e = object_path_startswith(node, prefix);
-                if (e)
+                if (e && e[0])
                         fprintf(i->f, " <node name=\"%s\"/>\n", e);
 
                 free(node);
                         fprintf(i->f, " <node name=\"%s\"/>\n", e);
 
                 free(node);