aboutsummaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorrmudgett <rmudgett@f38db490-d61c-443f-a65b-d21fe96a405b>2011-02-03 00:15:07 +0000
committerrmudgett <rmudgett@f38db490-d61c-443f-a65b-d21fe96a405b>2011-02-03 00:15:07 +0000
commitc9d7b8a0518cafcd949528ac9d378e761918c55d (patch)
tree1abdbb1c0c54a90351d3ea3fd6e072a03e02dcbf /apps
parent70fd3ba0a975322413cd73f477cccc497187beb7 (diff)
Merged revisions 305888 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r305888 | rmudgett | 2011-02-02 18:02:43 -0600 (Wed, 02 Feb 2011) | 8 lines Minor AST_FRAME_TEXT related issues. * Include the null terminator in the buffer length. When the frame is queued it is copied. If the null terminator is not part of the frame buffer length, the receiver could see garbage appended onto it. * Add channel lock protection with ast_sendtext(). * Fixed AMI SendText action ast_sendtext() return value check. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@305889 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps')
-rw-r--r--apps/app_sendtext.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/app_sendtext.c b/apps/app_sendtext.c
index f890ae4bf..5a9f66734 100644
--- a/apps/app_sendtext.c
+++ b/apps/app_sendtext.c
@@ -99,10 +99,10 @@ static int sendtext_exec(struct ast_channel *chan, void *data)
return 0;
}
status = "FAILURE";
- ast_channel_unlock(chan);
res = ast_sendtext(chan, args.text);
if (!res)
status = "SUCCESS";
+ ast_channel_unlock(chan);
pbx_builtin_setvar_helper(chan, "SENDTEXTSTATUS", status);
return 0;
}