TT#14008 fix call iterator dead lock

... should acually be working one of these days...

Change-Id: I8025aafd0eccb10df5ac2630e0e39b7fe978e25e
pull/1346/head
Richard Fuchs 4 years ago
parent 0266886487
commit 9952647d19

@ -2844,6 +2844,7 @@ void call_destroy(struct call *c) {
if (prev_call) { if (prev_call) {
if (mutex_trylock(&prev_call->iterator[i].next_lock)) { if (mutex_trylock(&prev_call->iterator[i].next_lock)) {
mutex_unlock(&c->iterator[i].next_lock); mutex_unlock(&c->iterator[i].next_lock);
mutex_unlock(&c->iterator[i].prev_lock);
mutex_unlock(&rtpe_call_iterators[i].lock); mutex_unlock(&rtpe_call_iterators[i].lock);
continue; // try again continue; // try again
} }
@ -2852,6 +2853,7 @@ void call_destroy(struct call *c) {
if (mutex_trylock(&next_call->iterator[i].prev_lock)) { if (mutex_trylock(&next_call->iterator[i].prev_lock)) {
mutex_unlock(&prev_call->iterator[i].next_lock); mutex_unlock(&prev_call->iterator[i].next_lock);
mutex_unlock(&c->iterator[i].next_lock); mutex_unlock(&c->iterator[i].next_lock);
mutex_unlock(&c->iterator[i].prev_lock);
mutex_unlock(&rtpe_call_iterators[i].lock); mutex_unlock(&rtpe_call_iterators[i].lock);
continue; // try again continue; // try again
} }

Loading…
Cancel
Save