summaryrefslogtreecommitdiffstats
path: root/src/pulsecore
diff options
context:
space:
mode:
authorColin Guthrie <cguthrie@mandriva.org>2011-03-25 23:43:26 +0000
committerColin Guthrie <cguthrie@mandriva.org>2011-03-25 23:43:26 +0000
commit1e381fbffc190fdede27d6f27a2d113daf3e791d (patch)
tree4a74a0e2fef5be3d374bdc3e5b63aec141b34350 /src/pulsecore
parent7aa8a3fa8015d17240e5fc27bf44eb7d22e7e13a (diff)
dbus: Do not refcnt the core.
We should not call pa_core_ref() anywhere in the code. Doing so will prevent proper daemon shutdown as the only call (in daemon/main.c) to pa_core_unref() should always call free_core() and perform a normal shutdown (i.e. unload all modules gracefully).
Diffstat (limited to 'src/pulsecore')
-rw-r--r--src/pulsecore/protocol-dbus.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/pulsecore/protocol-dbus.c b/src/pulsecore/protocol-dbus.c
index 13c05d92..c3299157 100644
--- a/src/pulsecore/protocol-dbus.c
+++ b/src/pulsecore/protocol-dbus.c
@@ -125,7 +125,7 @@ static pa_dbus_protocol *dbus_protocol_new(pa_core *c) {
p = pa_xnew(pa_dbus_protocol, 1);
PA_REFCNT_INIT(p);
- p->core = pa_core_ref(c);
+ p->core = c;
p->objects = pa_hashmap_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
p->connections = pa_hashmap_new(pa_idxset_trivial_hash_func, pa_idxset_trivial_compare_func);
p->extensions = pa_idxset_new(pa_idxset_string_hash_func, pa_idxset_string_compare_func);
@@ -178,8 +178,6 @@ void pa_dbus_protocol_unref(pa_dbus_protocol *p) {
pa_assert_se(pa_shared_remove(p->core, "dbus-protocol") >= 0);
- pa_core_unref(p->core);
-
pa_xfree(p);
}