summaryrefslogtreecommitdiff
path: root/addons/chan_ooh323.c
diff options
context:
space:
mode:
Diffstat (limited to 'addons/chan_ooh323.c')
-rw-r--r--addons/chan_ooh323.c19
1 files changed, 6 insertions, 13 deletions
diff --git a/addons/chan_ooh323.c b/addons/chan_ooh323.c
index 06096507f..4ab90be3a 100644
--- a/addons/chan_ooh323.c
+++ b/addons/chan_ooh323.c
@@ -1282,7 +1282,7 @@ static int ooh323_indicate(struct ast_channel *ast, int condition, const void *d
struct ooh323_pvt *p = (struct ooh323_pvt *) ast_channel_tech_pvt(ast);
char *callToken = (char *)NULL;
- int res = -1;
+ int res = -1, rres;
if (!p) return -1;
@@ -1329,11 +1329,9 @@ static int ooh323_indicate(struct ast_channel *ast, int condition, const void *d
case AST_CONTROL_PROGRESS:
if (ast_channel_state(ast) != AST_STATE_UP) {
if (!p->progsent) {
+ rres = ooManualProgress(callToken);
if (gH323Debug) {
- ast_debug(1, "Sending manual progress for %s, res = %u\n", callToken,
- ooManualProgress(callToken));
- } else {
- ooManualProgress(callToken);
+ ast_debug(1, "Sending manual progress for %s, res = %u\n", callToken, rres);
}
p->progsent = 1;
}
@@ -1342,12 +1340,9 @@ static int ooh323_indicate(struct ast_channel *ast, int condition, const void *d
case AST_CONTROL_RINGING:
if (ast_channel_state(ast) == AST_STATE_RING || ast_channel_state(ast) == AST_STATE_RINGING) {
if (!p->alertsent) {
+ rres = ooManualRingback(callToken);
if (gH323Debug) {
- ast_debug(1, "Sending manual ringback for %s, res = %u\n",
- callToken,
- ooManualRingback(callToken));
- } else {
- ooManualRingback(callToken);
+ ast_debug(1, "Sending manual ringback for %s, res = %u\n", callToken, rres);
}
p->alertsent = 1;
}
@@ -5058,9 +5053,7 @@ struct ast_frame *ooh323_rtp_read(struct ast_channel *ast, struct ooh323_pvt *p)
ast_log(LOG_NOTICE, "Failed to async goto '%s' into fax of '%s'\n", ast_channel_name(p->owner),target_context);
}
p->faxdetected = 1;
- if (dfr) {
- ast_frfree(dfr);
- }
+ ast_frfree(dfr);
return &ast_null_frame;
}
}