mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-03 11:25:35 +00:00
Simple lock, assignment, unlock sandwich optimization.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390439 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -18,7 +18,7 @@
|
||||
|
||||
/*! \file
|
||||
*
|
||||
* \brief Native RTP bridging module
|
||||
* \brief Native RTP bridging technology module
|
||||
*
|
||||
* \author Joshua Colp <jcolp@digium.com>
|
||||
*
|
||||
@@ -251,15 +251,13 @@ static int native_rtp_bridge_framehook_attach(struct ast_bridge_channel *bridge_
|
||||
}
|
||||
|
||||
ast_channel_lock(bridge_channel->chan);
|
||||
|
||||
if (!(data->id = ast_framehook_attach(bridge_channel->chan, &hook)) < 0) {
|
||||
ast_channel_unlock(bridge_channel->chan);
|
||||
data->id = ast_framehook_attach(bridge_channel->chan, &hook);
|
||||
ast_channel_unlock(bridge_channel->chan);
|
||||
if (!data->id < 0) {
|
||||
ao2_cleanup(data);
|
||||
return -1;
|
||||
}
|
||||
|
||||
ast_channel_unlock(bridge_channel->chan);
|
||||
|
||||
bridge_channel->bridge_pvt = data;
|
||||
|
||||
return 0;
|
||||
|
Reference in New Issue
Block a user