unload tunnel modules from a new stack frame

This commit is contained in:
Lennart Poettering 2008-12-17 21:27:07 +01:00
parent b95539b18b
commit f5d40fa448

View file

@ -286,7 +286,7 @@ static void browser_cb(
struct tunnel *t2; struct tunnel *t2;
if ((t2 = pa_hashmap_get(u->tunnels, t))) { if ((t2 = pa_hashmap_get(u->tunnels, t))) {
pa_module_unload_by_index(u->core, t2->module_index, TRUE); pa_module_unload_request_by_index(u->core, t2->module_index, TRUE);
pa_hashmap_remove(u->tunnels, t2); pa_hashmap_remove(u->tunnels, t2);
tunnel_free(t2); tunnel_free(t2);
} }
@ -427,7 +427,7 @@ void pa__done(pa_module*m) {
struct tunnel *t; struct tunnel *t;
while ((t = pa_hashmap_steal_first(u->tunnels))) { while ((t = pa_hashmap_steal_first(u->tunnels))) {
pa_module_unload_by_index(u->core, t->module_index, TRUE); pa_module_unload_request_by_index(u->core, t->module_index, TRUE);
tunnel_free(t); tunnel_free(t);
} }