summaryrefslogtreecommitdiff
path: root/src/libstddjb/str_len.c
blob: 4db2f4cbeb45796b0575052d48cc91ffb1eb4e10 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
/* ISC license. */

#include <skalibs/config.h>

#ifdef SKALIBS_FLAG_REPLACE_LIBC

#include <skalibs/bytestr.h>

unsigned int str_len (char const *s)
{
  register char const *t = s ;
  for (;;)
  {
    if (!*t) return t - s; ++t;
    if (!*t) return t - s; ++t;
    if (!*t) return t - s; ++t;
    if (!*t) return t - s; ++t;
  }
}

#endif