/* * s t r l e n . c */ /*)LIBRARY */ #ifdef DOCUMENTATION title strlen String Length index String length synopsis .s.nf unsigned int strlen(s); char *s; .s.f Description Return the length of the argument string. Bugs #endif #define EOS 0 unsigned int strlen(s) register char *s; /* * Length of string */ { register char *sp; for (sp = s; *sp++ != EOS;) ; return (sp - s - 1); }