mirror of
https://github.com/asterisk/asterisk.git
synced 2025-11-01 11:32:25 +00:00
(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: https://origsvn.digium.com/svn/asterisk/trunk@144569 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -1299,7 +1299,7 @@ static void store_mixer(struct chan_oss_pvt *o, const char *s)
|
||||
int i;
|
||||
|
||||
for (i = 0; i < strlen(s); i++) {
|
||||
if (!isalnum(s[i]) && index(" \t-/", s[i]) == NULL) {
|
||||
if (!isalnum(s[i]) && strchr(" \t-/", s[i]) == NULL) {
|
||||
ast_log(LOG_WARNING, "Suspect char %c in mixer cmd, ignoring:\n\t%s\n", s[i], s);
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user