}
}
-static char *find_tok(char *str)
+static const char *find_tok(const char *str)
{
while(*str == ' ') {
str++;
return str;
}
-static char *find_sep(char *str)
+static const char *find_sep(const char *str)
{
while(*str != ' ') {
str++;
return str;
}
-int nth_token_is(char *str, char *token, int tok_no)
+int nth_token_is(const char *str, const char *token, int tok_no)
{
int i;
- char *start;
- char *end;
+ const char *start;
+ const char *end;
for(i=0; i<=tok_no; i++) {
str = find_tok(str);
return 1;
}
-char *nth_token(char *str, int tok_no)
+char *nth_token(const char *str, int tok_no)
{
static char *retval = NULL;
int i;
- char *start;
- char *end;
+ const char *start;
+ const char *end;
for(i=0; i<=tok_no; i++) {
str = find_tok(str);
extern int ustcomm_disconnect(struct ustcomm_connection *conn);
extern int ustcomm_close_all_connections(struct ustcomm_server *server);
-extern int nth_token_is(char *str, char *token, int tok_no);
+extern int nth_token_is(const char *str, const char *token, int tok_no);
-extern char *nth_token(char *str, int tok_no);
+extern char *nth_token(const char *str, int tok_no);
extern int pid_is_online(pid_t);