Commit 8db7bdfa authored by Youness Alaoui's avatar Youness Alaoui
Browse files

unlock the mutex before calling the recv callback

parent 2faa76a4
......@@ -2073,8 +2073,14 @@ nice_agent_g_source_cb (
MAX_BUFFER_SIZE, buf);
if (len > 0 && component->g_source_io_cb) {
component->g_source_io_cb (agent, stream->id, component->id,
len, buf, component->data);
gpointer data = component->data;
gint sid = stream->id;
gint cid = component->id;
NiceAgentRecvFunc callback = component->g_source_io_cb;
/* Unlock the agent before calling the callback */
agent_unlock();
callback (agent, sid, cid, len, buf, data);
goto done;
} else if (len < 0) {
GSource *source = ctx->source;
component->gsources = g_slist_remove (component->gsources, source);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment