aboutsummaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authormurf <murf@f38db490-d61c-443f-a65b-d21fe96a405b>2008-09-25 22:23:21 +0000
committermurf <murf@f38db490-d61c-443f-a65b-d21fe96a405b>2008-09-25 22:23:21 +0000
commit98f0dbb71a9732df94209c6b916d9ab9244c7194 (patch)
tree60fe6b1b2aca47ef011eee35faf02931224540da /apps
parent33753a97901e0039d33e884d2dbf6161440b2805 (diff)
Merged revisions 144569 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk ........ r144569 | murf | 2008-09-25 16:21:28 -0600 (Thu, 25 Sep 2008) | 14 lines (closes issue #13557) Reported by: nickpeirson The user attached a patch, but the license is not yet recorded. I took the liberty of finding and replacing ALL index() calls with strchr() calls, and that involves more than just main/pbx.c; chan_oss, app_playback, func_cut also had calls to index(), and I changed them out. 1.4 had no references to index() at all. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.0@144570 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps')
-rw-r--r--apps/app_playback.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/apps/app_playback.c b/apps/app_playback.c
index c7d8ff620..cb30b7a9d 100644
--- a/apps/app_playback.c
+++ b/apps/app_playback.c
@@ -200,13 +200,13 @@ static int do_say(say_args_t *a, const char *s, const char *options, int depth)
ast_debug(2, "doing [%s]\n", fn);
/* locate prefix and data, if any */
- fmt = index(fn, ':');
+ fmt = strchr(fn, ':');
if (!fmt || fmt == fn) { /* regular filename */
ret = s_streamwait3(a, fn);
continue;
}
fmt++;
- data = index(fmt, ':'); /* colon before data */
+ data = strchr(fmt, ':'); /* colon before data */
if (!data || data == fmt) { /* simple prefix-fmt */
ret = do_say(a, fn, options, depth);
continue;
@@ -219,14 +219,14 @@ static int do_say(say_args_t *a, const char *s, const char *options, int depth)
if (*p == '\'') {/* file name - we trim them */
char *y;
strcpy(fn2, ast_skip_blanks(p+1)); /* make a full copy */
- y = index(fn2, '\'');
+ y = strchr(fn2, '\'');
if (!y) {
p = data; /* invalid. prepare to end */
break;
}
*y = '\0';
ast_trim_blanks(fn2);
- p = index(p+1, '\'');
+ p = strchr(p+1, '\'');
ret = s_streamwait3(a, fn2);
} else {
int l = fmt-fn;