Annotation of coherent/b/lib/libc/string/strcspn.c, revision 1.1

1.1     ! root        1: /*
        !             2:  * strcspn.c
        !             3:  * ANSI 4.11.5.3.
        !             4:  * Search string for characters not in string.
        !             5:  */
        !             6: 
        !             7: #include <string.h>
        !             8: 
        !             9: size_t *strcspn(s1, s2) char *s1; char *s2;
        !            10: {
        !            11:        register char *cp1, *cp2;
        !            12:        register char c1, c2;
        !            13: 
        !            14:        for (cp1 = s1; c1 = *cp1; cp1++)
        !            15:                for (cp2 = s2; c2 = *cp2; cp2++)
        !            16:                        if (c1 == c2)
        !            17:                                return((size_t)(cp1 - s1));
        !            18:        return((size_t)(cp1 - s1));
        !            19: }

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.