:pserver:cvsanon@mok.lvcm.com:/CVS/ReactOS reactos
[reactos.git] / lib / crtdll / string / strchr.c
1 /* Copyright (C) 1996 DJ Delorie, see COPYING.DJ for details */
2 /* Copyright (C) 1994 DJ Delorie, see COPYING.DJ for details */
3
4
5
6 char *strchr(const char *s, int c);
7
8 char *strchr(const char *s, int c)
9 {
10   char cc = c;
11   while (*s)
12   {
13     if (*s == cc)
14       return (char *)s;
15     s++;
16   }
17   if (cc == 0)
18     return (char *)s;
19   return 0;
20 }
21