Skip to content
Snippets Groups Projects
Commit 513756b9 authored by Joshua Colp's avatar Joshua Colp
Browse files

res_calendar: Protect channel when adding datastore.

This change adds a missing channel lock when adding a datastore
to a channel.
........

Merged revisions 404135 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 404136 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 404137 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404138 65c4cc65-6c06-0410-ace0-fbb531ad65f3
parent 2a6df87f
No related branches found
No related tags found
No related merge requests found
......@@ -775,7 +775,10 @@ static void *do_notify(void *data)
datastore->inheritance = DATASTORE_INHERIT_FOREVER;
ao2_ref(event, +1);
ast_channel_lock(chan);
res = ast_channel_datastore_add(chan, datastore);
ast_channel_unlock(chan);
if (!(tmpstr = ast_str_create(32))) {
goto notify_cleanup;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment