1 /* -*- linux-c -*- ------------------------------------------------------- *
3 * Copyright (C) 1991, 1992 Linus Torvalds
4 * Copyright 2007 rPath, Inc. - All Rights Reserved
6 * This file is part of the Linux kernel, and is made available under
7 * the terms of the GNU General Public License version 2.
9 * ----------------------------------------------------------------------- */
12 * Very basic string functions
17 int strcmp(const char *str1, const char *str2)
19 const unsigned char *s1 = (const unsigned char *)str1;
20 const unsigned char *s2 = (const unsigned char *)str2;
33 size_t strnlen(const char *s, size_t maxlen)
36 while (*es && maxlen) {
44 unsigned int atou(const char *s)
48 i = i * 10 + (*s++ - '0');