summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJordan K. Hubbard <jkh@FreeBSD.org>2003-12-18 07:44:53 +0000
committerJordan K. Hubbard <jkh@FreeBSD.org>2003-12-18 07:44:53 +0000
commitfee66713adfa80bcbcfca34f37cb455a2129fd8b (patch)
treef56a053adf939ab1a6ac83ca6c3935b30509362c
parentf415f20926b5aaeab8db5b15f6f4a60cd4cd18b4 (diff)
Notes
-rw-r--r--lib/libc/string/index.c4
-rw-r--r--lib/libc/string/rindex.c3
2 files changed, 5 insertions, 2 deletions
diff --git a/lib/libc/string/index.c b/lib/libc/string/index.c
index fe523be40f86..5d79f4f7741c 100644
--- a/lib/libc/string/index.c
+++ b/lib/libc/string/index.c
@@ -52,7 +52,9 @@ index
#endif
(const char *p, int ch)
{
- char c = ch;
+ char c;
+
+ c = ch;
for (;; ++p) {
if (*p == c)
return ((char *)p);
diff --git a/lib/libc/string/rindex.c b/lib/libc/string/rindex.c
index 9deeb1fb209c..641c00f7ee89 100644
--- a/lib/libc/string/rindex.c
+++ b/lib/libc/string/rindex.c
@@ -53,8 +53,9 @@ rindex
(const char *p, int ch)
{
char *save;
- char c = ch;
+ char c;
+ c = ch;
for (save = NULL;; ++p) {
if (*p == c)
save = (char *)p;