diff options
Diffstat (limited to 'src/libstddjb/sagethostname.c')
-rw-r--r-- | src/libstddjb/sagethostname.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libstddjb/sagethostname.c b/src/libstddjb/sagethostname.c index 500a95c..b20db39 100644 --- a/src/libstddjb/sagethostname.c +++ b/src/libstddjb/sagethostname.c @@ -1,13 +1,13 @@ /* ISC license. */ #include <unistd.h> -#include <skalibs/bytestr.h> +#include <string.h> #include <skalibs/stralloc.h> #include <skalibs/djbunix.h> int sagethostname (stralloc *sa) { - unsigned int n = 128 ; + size_t n = 128 ; int wasnull = !sa->s ; for (;;) @@ -18,7 +18,7 @@ int sagethostname (stralloc *sa) if (!sa->s[sa->len + n - 2]) break ; n += 128 ; } - sa->len += str_len(sa->s + sa->len) ; + sa->len += strlen(sa->s + sa->len) ; return 0 ; err: |