1 //-----------------------------------------------------------------------------
2 // Jonathan Westhues, Aug 2005
3 // Copyright (C) 2010 Hector Martin "marcan" <marcan@marcansoft.com>
5 // This code is licensed to you under the terms of the GNU GPL, version 2 or,
6 // at your option, any later version. See the LICENSE.txt file for the text of
8 //-----------------------------------------------------------------------------
9 // Common string.h functions
10 //-----------------------------------------------------------------------------
17 int strlen(const char *str
);
18 void *memcpy(void *dest
, const void *src
, int len
);
19 void *memmove(void *dest
, const void *src
, size_t len
);
20 void *memset(void *dest
, uint8_t c
, int len
);
21 int memcmp(const void *av
, const void *bv
, int len
);
22 void memxor(uint8_t *dest
, uint8_t *src
, size_t len
);
23 char *strncat(char *dest
, const char *src
, unsigned int n
);
24 char *strcat(char *dest
, const char *src
);
25 void strreverse(char s
[]);
26 void itoa(int n
, char s
[]);
27 char *strcpy(char *dst
, const char *src
);
28 char *strncpy(char *dst
, const char *src
, size_t n
);
29 int strcmp(const char *s1
, const char *s2
);
30 char *strtok(char *s
, const char *delim
);
31 char *strchr(const char *s
, int c
);
32 size_t strspn(const char *s1
, const char *s2
);
33 char *strrchr(const char *s
, int c
);
34 size_t strcspn(const char *s1
, const char *s2
);
35 char *strpbrk(const char *s1
, const char *s2
);
36 int strncmp(const char *s1
, const char *s2
, size_t n
);
37 unsigned long strtoul(const char *p
, char **out_p
, int base
);
38 long strtol(const char *p
, char **out_p
, int base
);
39 char c_tolower(int c
);
40 char c_isprint(unsigned char c
);
42 #endif /* __STRING_H */