aboutsummaryrefslogtreecommitdiffstats
path: root/channels
diff options
context:
space:
mode:
authorkpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b>2009-03-13 16:55:38 +0000
committerkpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b>2009-03-13 16:55:38 +0000
commitb85c11f49a228fb126bc9d6df75fe03fbcad202f (patch)
treefec0d1a3c9a071ab08007273a6432b21f548f330 /channels
parent6e91b103e46439a541a8061234a22b72d33e880e (diff)
improve a bit of suboptimal code
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@181985 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels')
-rw-r--r--channels/chan_sip.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index a2bb9fcba..5d80ef321 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -19865,11 +19865,7 @@ static int acf_channel_read(struct ast_channel *chan, const char *funcname, char
} else if (!strcasecmp(args.param, "peername")) {
ast_copy_string(buf, p->peername, buflen);
} else if (!strcasecmp(args.param, "t38passthrough")) {
- if (p->t38.state == T38_DISABLED) {
- ast_copy_string(buf, "0", sizeof("0"));
- } else { /* T38 is offered or enabled in this call */
- ast_copy_string(buf, "1", sizeof("1"));
- }
+ ast_copy_string(buf, (p->t38.state == T38_DISABLED) ? "0" : "1", buflen);
} else if (!strcasecmp(args.param, "rtpdest")) {
struct sockaddr_in sin;