source: trunk/sys/dietlibc/strspn.c @ 147

Last change on this file since 147 was 1, checked in by alain, 8 years ago

First import

File size: 234 bytes
RevLine 
[1]1#include <string.h>
2
3size_t strspn(const char *s, const char *accept)
4{
5  size_t l = 0;
6  const char *a;
7
8  for (; *s; s++) {
9    for (a = accept; *a && *s != *a; a++);
10
11    if (!*a)
12      break;
13    else
14     l++;
15  }
16
17  return l;
18}
Note: See TracBrowser for help on using the repository browser.