Add gettokens() string function

This commit is contained in:
Nils O. Selåsdal
2016-01-08 09:43:04 +01:00
parent 9b70b64729
commit a686ba1975
2 changed files with 60 additions and 1 deletions
+2 -1
View File
@@ -96,7 +96,8 @@ char* uc_sprintbs(char *result, unsigned short value);
/** Like http://swtch.com/plan9port/man/man3/getfields.html
*/
int getfields(char *str, char **args, int max, int mflag, const char *set);
int getfields(char *str, char **args, int max, int mflag, const char *sep);
int gettokens(char *str, char **args, int max, const char *sep);
//Converts bytes to a human representable test, (i.e. 12kB, 160 MB 1.78 GB etc.)
///result should be at least of size 12,