00001 /* 00002 * (c) copyright 1987 by the Vrije Universiteit, Amsterdam, The Netherlands. 00003 * See the copyright notice in the ACK home directory, in the file "Copyright". 00004 */ 00005 /* $Header: /opt/proj/minix/cvsroot/src/lib/ansi/strchr.c,v 1.1.1.1 2005/04/21 14:56:06 beng Exp $ */ 00006 00007 #include <string.h> 00008 00009 char * 00010 strchr(register const char *s, register int c) 00011 { 00012 c = (char) c; 00013 00014 while (c != *s) { 00015 if (*s++ == '\0') return NULL; 00016 } 00017 return (char *)s; 00018 }
1.4.6