misc: replace index() with strchr()

Type: improvement
Change-Id: I471e514ebef0b4c1f86067115b2ebe5a5517c6fb
Signed-off-by: Matus Fabian <matfabia@cisco.com>
This commit is contained in:
Matus Fabian
2024-07-22 09:56:01 +02:00
committed by Florin Coras
parent 7561c45bcc
commit 7f163b682a
4 changed files with 4 additions and 4 deletions

View File

@ -2151,7 +2151,7 @@ elog_save (vat_main_t * vam)
}
/* It's fairly hard to get "../oopsie" through unformat; just in case */
if (strstr (file, "..") || index (file, '/'))
if (strstr (file, "..") || strchr (file, '/'))
{
errmsg ("illegal characters in filename '%s'", file);
return 0;