Lines Matching refs:s1
51 * The prefix function returns 0 if *s1 is not a prefix
52 * of *s2. If *s1 exactly matches *s2, the negative of
53 * the length is returned. If *s1 is a prefix of *s2,
54 * the length of *s1 is returned.
57 isprefix(char *s1, const char *s2)
62 if (*s1 == '\0')
64 os1 = s1;
65 c1 = *s1;
70 c1 = *++s1;
73 return(*s1 ? 0 : (*s2 ? (s1 - os1) : (os1 - s1)));