pathIsBaseName() added to utils.c

The function is used to test that the specified string looks like just
as the basename of a path, without any absolute or relative path.
This commit is contained in:
antirez
2013-07-02 12:08:07 +02:00
parent 0781ad6899
commit 6978aeb3bf
2 changed files with 9 additions and 0 deletions

View File

@ -40,5 +40,6 @@ int string2ll(const char *s, size_t slen, long long *value);
int string2l(const char *s, size_t slen, long *value);
int d2string(char *buf, size_t len, double value);
sds getAbsolutePath(char *filename);
int pathIsBaseName(char *path);
#endif