aboutsummaryrefslogtreecommitdiffstats
path: root/app.c
diff options
context:
space:
mode:
authormarkster <markster@f38db490-d61c-443f-a65b-d21fe96a405b>2005-03-23 05:56:32 +0000
committermarkster <markster@f38db490-d61c-443f-a65b-d21fe96a405b>2005-03-23 05:56:32 +0000
commit4a7019a16af31fc5be3bd46a753805760cde5da9 (patch)
treefacf25d45bde66df632cfdb514fe09da93cc4386 /app.c
parent2b84c4638e6085cb34c3173677e67ea55c42c7c7 (diff)
Merge Russell's formatting patch (bug #3838)
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@5234 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'app.c')
-rwxr-xr-xapp.c18
1 files changed, 11 insertions, 7 deletions
diff --git a/app.c b/app.c
index 5621773dd..0ea51f8a6 100755
--- a/app.c
+++ b/app.c
@@ -58,9 +58,9 @@ int ast_app_dtget(struct ast_channel *chan, const char *context, char *collect,
timeout = 5;
ts = ast_get_indication_tone(chan->zone,"dial");
- if (ts && ts->data[0]) {
- res = ast_playtones_start(chan, 0, ts->data, 0);
- } else
+ if (ts && ts->data[0])
+ res = ast_playtones_start(chan, 0, ts->data, 0);
+ else
ast_log(LOG_NOTICE,"Huh....? no dial for indications?\n");
for (x = strlen(collect); strlen(collect) < maxlen; ) {
@@ -105,8 +105,10 @@ int ast_app_getdata(struct ast_channel *c, char *prompt, char *s, int maxlen, in
fto = c->pbx ? c->pbx->rtimeout * 1000 : 6000;
to = c->pbx ? c->pbx->dtimeout * 1000 : 2000;
- if (timeout > 0) fto = to = timeout;
- if (timeout < 0) fto = to = 1000000000;
+ if (timeout > 0)
+ fto = to = timeout;
+ if (timeout < 0)
+ fto = to = 1000000000;
res = ast_readstring(c, s, maxlen, to, fto, "#");
return res;
}
@@ -122,8 +124,10 @@ int ast_app_getdata_full(struct ast_channel *c, char *prompt, char *s, int maxle
}
fto = 6000;
to = 2000;
- if (timeout > 0) fto = to = timeout;
- if (timeout < 0) fto = to = 1000000000;
+ if (timeout > 0)
+ fto = to = timeout;
+ if (timeout < 0)
+ fto = to = 1000000000;
res = ast_readstring_full(c, s, maxlen, to, fto, "#", audiofd, ctrlfd);
return res;
}