added index and rindex to libroot.so
R5 ftp and telnet commands now run on Haiku git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14362 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -78,6 +78,8 @@ extern const char *strsignal(int signal);
|
|||||||
#define bzero(buffer, length) memset((buffer), 0, (length))
|
#define bzero(buffer, length) memset((buffer), 0, (length))
|
||||||
|
|
||||||
extern int ffs(int i);
|
extern int ffs(int i);
|
||||||
|
extern char *index(const char *s, int c);
|
||||||
|
extern char *rindex(char const *s, int c);
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,3 +16,10 @@ strchr(const char *s, int c)
|
|||||||
return (char *)s;
|
return (char *)s;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
char *
|
||||||
|
index(const char *s, int c)
|
||||||
|
{
|
||||||
|
return strchr(s, c);
|
||||||
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -22,3 +22,11 @@ strrchr(char const *s, int c)
|
|||||||
|
|
||||||
return (char *)last;
|
return (char *)last;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
char *
|
||||||
|
rindex(char const *s, int c)
|
||||||
|
{
|
||||||
|
return strrchr(s, c);
|
||||||
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user