From a2c4bf22e0813d529f153c01d7421345a792f3bc Mon Sep 17 00:00:00 2001 From: Arun Raghavan Date: Tue, 3 Jul 2012 18:00:36 +0530 Subject: [PATCH] Revert "role-cork: Fix a minor leak" This reverts commit 51c8d5a477d36f0646243a092994036b3781e9c1. As David points out, this was incorrect. --- src/modules/module-role-cork.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modules/module-role-cork.c b/src/modules/module-role-cork.c index 8d003da0f..a4270a4fd 100644 --- a/src/modules/module-role-cork.c +++ b/src/modules/module-role-cork.c @@ -227,7 +227,7 @@ int pa__init(pa_module *m) { char *n = NULL; while ((n = pa_split(roles, ",", &split_state))) if (n[0] != '\0') - pa_idxset_put(u->trigger_roles, n, NULL); + pa_idxset_put(u->trigger_roles, pa_xstrdup(n), NULL); } if (pa_idxset_isempty(u->trigger_roles)) { pa_log_debug("Using role 'phone' as trigger role."); @@ -241,7 +241,7 @@ int pa__init(pa_module *m) { char *n = NULL; while ((n = pa_split(roles, ",", &split_state))) if (n[0] != '\0') - pa_idxset_put(u->cork_roles, n, NULL); + pa_idxset_put(u->cork_roles, pa_xstrdup(n), NULL); } if (pa_idxset_isempty(u->cork_roles)) { pa_log_debug("Using roles 'music' and 'video' as cork roles.");