summaryrefslogtreecommitdiff
path: root/apps/app_chanspy.c
diff options
context:
space:
mode:
authorTerry Wilson <twilson@digium.com>2012-03-13 18:20:34 +0000
committerTerry Wilson <twilson@digium.com>2012-03-13 18:20:34 +0000
commit786f5898d12d30c481b1d178bb80e5801dbf666f (patch)
tree2b5e07ed1b5fbd7aae1187f068eff498621878a2 /apps/app_chanspy.c
parent73ec67e008ca6db76625bfc1f992fa726c948837 (diff)
Finalize ast_channel opaquification
Review: https://reviewboard.asterisk.org/r/1786/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@358907 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'apps/app_chanspy.c')
-rw-r--r--apps/app_chanspy.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/apps/app_chanspy.c b/apps/app_chanspy.c
index e773c4789..cafc62b39 100644
--- a/apps/app_chanspy.c
+++ b/apps/app_chanspy.c
@@ -489,7 +489,7 @@ static int start_spying(struct ast_autochan *autochan, const char *spychan_name,
ast_set_flag(audiohook, AST_AUDIOHOOK_TRIGGER_SYNC | AST_AUDIOHOOK_SMALL_QUEUE);
res = ast_audiohook_attach(autochan->chan, audiohook);
- if (!res && ast_test_flag(autochan->chan, AST_FLAG_NBRIDGE) && (peer = ast_bridged_channel(autochan->chan))) {
+ if (!res && ast_test_flag(ast_channel_flags(autochan->chan), AST_FLAG_NBRIDGE) && (peer = ast_bridged_channel(autochan->chan))) {
ast_softhangup(peer, AST_SOFTHANGUP_UNBRIDGE);
}
return res;
@@ -583,7 +583,7 @@ static int channel_spy(struct ast_channel *chan, struct ast_autochan *spyee_auto
}
ast_channel_lock(chan);
- ast_set_flag(chan, AST_FLAG_END_DTMF_ONLY);
+ ast_set_flag(ast_channel_flags(chan), AST_FLAG_END_DTMF_ONLY);
ast_channel_unlock(chan);
csth.volfactor = *volfactor;
@@ -699,7 +699,7 @@ static int channel_spy(struct ast_channel *chan, struct ast_autochan *spyee_auto
ast_deactivate_generator(chan);
ast_channel_lock(chan);
- ast_clear_flag(chan, AST_FLAG_END_DTMF_ONLY);
+ ast_clear_flag(ast_channel_flags(chan), AST_FLAG_END_DTMF_ONLY);
ast_channel_unlock(chan);
if (ast_test_flag(flags, OPTION_WHISPER | OPTION_BARGE | OPTION_DTMF_SWITCH_MODES)) {
@@ -787,7 +787,7 @@ static int common_exec(struct ast_channel *chan, struct ast_flags *flags,
if (ast_channel_state(chan) != AST_STATE_UP)
ast_answer(chan);
- ast_set_flag(chan, AST_FLAG_SPYING); /* so nobody can spy on us while we are spying */
+ ast_set_flag(ast_channel_flags(chan), AST_FLAG_SPYING); /* so nobody can spy on us while we are spying */
waitms = 100;
@@ -800,7 +800,7 @@ static int common_exec(struct ast_channel *chan, struct ast_flags *flags,
if (!res)
res = ast_waitstream(chan, "");
else if (res < 0) {
- ast_clear_flag(chan, AST_FLAG_SPYING);
+ ast_clear_flag(ast_channel_flags(chan), AST_FLAG_SPYING);
break;
}
if (!ast_strlen_zero(exitcontext)) {
@@ -831,7 +831,7 @@ static int common_exec(struct ast_channel *chan, struct ast_flags *flags,
res = ast_waitfordigit(chan, waitms);
if (res < 0) {
iter = ast_channel_iterator_destroy(iter);
- ast_clear_flag(chan, AST_FLAG_SPYING);
+ ast_clear_flag(ast_channel_flags(chan), AST_FLAG_SPYING);
break;
}
if (!ast_strlen_zero(exitcontext)) {
@@ -873,7 +873,7 @@ static int common_exec(struct ast_channel *chan, struct ast_flags *flags,
continue;
}
- if (ast_check_hangup(autochan->chan) || ast_test_flag(autochan->chan, AST_FLAG_SPYING)) {
+ if (ast_check_hangup(autochan->chan) || ast_test_flag(ast_channel_flags(autochan->chan), AST_FLAG_SPYING)) {
continue;
}
@@ -1024,7 +1024,7 @@ static int common_exec(struct ast_channel *chan, struct ast_flags *flags,
}
exit:
- ast_clear_flag(chan, AST_FLAG_SPYING);
+ ast_clear_flag(ast_channel_flags(chan), AST_FLAG_SPYING);
ast_channel_setoption(chan, AST_OPTION_TXGAIN, &zero_volume, sizeof(zero_volume), 0);