changed the "path" param to "dir" and added some more help text samples, for binary files, we now check for lower case ".bin" too
This commit is contained in:
1 parent
838a45cb84
commit
35d1bebf08
3 files changed
+47
-32
No files matched your search
@@ -1088,6 +1088,14 @@ void str_lower(char *s) {
|
||||
s[i] = tolower(s[i]);
|
||||
}
|
||||
|
||||
void str_upper(char *s) {
|
||||
strn_upper(s, strlen(s));
|
||||
}
|
||||
|
||||
void strn_upper(char *s, size_t n) {
|
||||
for (size_t i = 0; i < n; i++)
|
||||
s[i] = toupper(s[i]);
|
||||
}
|
||||
// check for prefix in string
|
||||
bool str_startswith(const char *s, const char *pre) {
|
||||
return strncmp(pre, s, strlen(pre)) == 0;
|
||||
|
||||
Reference in new issue
Block a user