summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDenis Kenzior <denis.kenzior@intel.com>2009-05-11 11:49:53 -0500
committerMarcel Holtmann <marcel@holtmann.org>2009-05-11 11:50:45 -0700
commit50ff91e20914e05bfc93e880620b2280ddb82e9f (patch)
treed7cd6e453c80ddea1d360f8436c255b7d41ea73b
parent6d486b7fe19945f4c01ccf98b40e83345cd78a2d (diff)
downloadofono-50ff91e20914e05bfc93e880620b2280ddb82e9f.tar.bz2
Make the parent path invalidateable
-rw-r--r--gdbus/object.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/gdbus/object.c b/gdbus/object.c
index 2823054b..31869218 100644
--- a/gdbus/object.c
+++ b/gdbus/object.c
@@ -307,7 +307,11 @@ static void invalidate_parent_data(DBusConnection *conn, const char *child_path)
if (!slash)
goto done;
- *slash = '\0';
+ if (slash == parent_path && parent_path[1] != '\0')
+ parent_path[1] = '\0';
+ else
+ *slash = '\0';
+
if (!strlen(parent_path))
goto done;