diff --git a/res/res_pjsip_outbound_publish.c b/res/res_pjsip_outbound_publish.c index 53e15a0..70350b2 100644 --- a/res/res_pjsip_outbound_publish.c +++ b/res/res_pjsip_outbound_publish.c @@ -813,6 +813,8 @@ static int publisher_client_send(void *obj, void *arg, void *data, int flags) message->body.body_text = strcpy(dst, body->body_text); } + SCOPED_AO2LOCK(lock, publisher); + AST_LIST_INSERT_TAIL(&publisher->queue, message, entry); *res = ast_sip_push_task(NULL, sip_publisher_service_queue, ao2_bump(publisher));