Merge pull request #180 from signalwire/CF_AUDIO

[mod_portaudio] CF_AUDIO flag is not set
This commit is contained in:
Andrey Volk 2020-01-06 22:35:03 +04:00 committed by GitHub
commit 8797a0f480
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 9 additions and 0 deletions

View File

@ -282,6 +282,14 @@ SWITCH_STANDARD_API(pa_cmd);
*/
static switch_status_t channel_on_init(switch_core_session_t *session)
{
switch_channel_t *channel;
if (session) {
if ((channel = switch_core_session_get_channel(session))) {
switch_channel_set_flag(channel, CF_AUDIO);
}
}
return SWITCH_STATUS_SUCCESS;
}
@ -1267,6 +1275,7 @@ static switch_call_cause_t channel_outgoing_channel(switch_core_session_t *sessi
switch_set_flag_locked(tech_pvt, TFLAG_OUTBOUND);
switch_channel_set_state(channel, CS_INIT);
switch_channel_set_flag(channel, CF_AUDIO);
return SWITCH_CAUSE_SUCCESS;
error: