]> Kevux Git Server - fll/commitdiff
Bugfix: Replace index() with strchr().
authorKevin Day <Kevin@kevux.org>
Wed, 4 Sep 2024 03:21:15 +0000 (22:21 -0500)
committerKevin Day <Kevin@kevux.org>
Wed, 4 Sep 2024 03:21:15 +0000 (22:21 -0500)
The `index()` function is deprecated.
Use the `strchr()` function instead.

level_0/f_environment/c/environment.c

index 80b8b3c99e4e4d03424579b375d863c5f4746a87..89a1ee3f12e4f4d2d4b9b64aeb3f94e4fd0c1bd2 100644 (file)
@@ -95,7 +95,7 @@ extern char **environ;
       map.key.used = 0;
       map.value.used = 0;
 
-      at = index(*string, f_string_ascii_equal_s.string[0]);
+      at = strchr(*string, f_string_ascii_equal_s.string[0]);
       if (!at || at == *string) continue;
 
       map.key.string = *string;