Merge pull request #483 from prife/master
[kservice] fix rt_strcmp/strncmp/strlen prototype
This commit is contained in:
commit
b2705d567a
|
@ -501,9 +501,9 @@ int *_rt_errno(void);
|
|||
void *rt_memset(void *src, int c, rt_ubase_t n);
|
||||
void *rt_memcpy(void *dest, const void *src, rt_ubase_t n);
|
||||
|
||||
rt_ubase_t rt_strncmp(const char *cs, const char *ct, rt_ubase_t count);
|
||||
rt_ubase_t rt_strcmp (const char *cs, const char *ct);
|
||||
rt_ubase_t rt_strlen (const char *src);
|
||||
rt_int32_t rt_strncmp(const char *cs, const char *ct, rt_ubase_t count);
|
||||
rt_int32_t rt_strcmp (const char *cs, const char *ct);
|
||||
rt_size_t rt_strlen (const char *src);
|
||||
char *rt_strdup(const char *s);
|
||||
|
||||
char *rt_strstr(const char *str1, const char *str2);
|
||||
|
|
|
@ -430,7 +430,7 @@ RTM_EXPORT(rt_strncpy);
|
|||
*
|
||||
* @return the result
|
||||
*/
|
||||
rt_ubase_t rt_strncmp(const char *cs, const char *ct, rt_ubase_t count)
|
||||
rt_int32_t rt_strncmp(const char *cs, const char *ct, rt_ubase_t count)
|
||||
{
|
||||
register signed char __res = 0;
|
||||
|
||||
|
@ -453,7 +453,7 @@ RTM_EXPORT(rt_strncmp);
|
|||
*
|
||||
* @return the result
|
||||
*/
|
||||
rt_ubase_t rt_strcmp(const char *cs, const char *ct)
|
||||
rt_int32_t rt_strcmp(const char *cs, const char *ct)
|
||||
{
|
||||
while (*cs && *cs == *ct)
|
||||
cs++, ct++;
|
||||
|
@ -470,7 +470,7 @@ RTM_EXPORT(rt_strcmp);
|
|||
*
|
||||
* @return the length of string
|
||||
*/
|
||||
rt_ubase_t rt_strlen(const char *s)
|
||||
rt_size_t rt_strlen(const char *s)
|
||||
{
|
||||
const char *sc;
|
||||
|
||||
|
|
Loading…
Reference in New Issue