summaryrefslogtreecommitdiffstats
path: root/src/modules
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2008-06-13 21:06:08 +0000
committerLennart Poettering <lennart@poettering.net>2008-06-13 21:06:08 +0000
commit5c149e2a794a22c9e4171a4f6af7175de79aa094 (patch)
treeb870c1e79fbd6105dcb7739ec3c78a6c96ff603b /src/modules
parentd39d6c921383c6930bc1c48ea3d950aa8834537d (diff)
fix a minor memory leak when unloading m-c-k
git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@2523 fefdeb5f-60dc-0310-8127-8f9354f1896f
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/module-console-kit.c8
-rw-r--r--src/modules/module-x11-xsmp.c1
2 files changed, 6 insertions, 3 deletions
diff --git a/src/modules/module-console-kit.c b/src/modules/module-console-kit.c
index 6e922bf2..12a09f81 100644
--- a/src/modules/module-console-kit.c
+++ b/src/modules/module-console-kit.c
@@ -322,8 +322,12 @@ void pa__done(pa_module *m) {
if (!(u = m->userdata))
return;
- while ((session = pa_hashmap_steal_first(u->sessions)))
- free_session(session);
+ if (u->sessions) {
+ while ((session = pa_hashmap_steal_first(u->sessions)))
+ free_session(session);
+
+ pa_hashmap_free(u->sessions, NULL, NULL);
+ }
if (u->connection)
pa_dbus_connection_unref(u->connection);
diff --git a/src/modules/module-x11-xsmp.c b/src/modules/module-x11-xsmp.c
index 9994f99d..ada9e143 100644
--- a/src/modules/module-x11-xsmp.c
+++ b/src/modules/module-x11-xsmp.c
@@ -52,7 +52,6 @@ PA_MODULE_VERSION(PACKAGE_VERSION);
PA_MODULE_LOAD_ONCE(TRUE);
PA_MODULE_USAGE("session_manager=<session manager string> display=<X11 display>");
-
static pa_bool_t ice_in_use = FALSE;
static const char* const valid_modargs[] = {