mirror of
https://github.com/cesanta/mongoose.git
synced 2025-01-20 17:03:12 +08:00
Fix compile of mg_strcasestr() under windows
This commit is contained in:
parent
3d211d89c5
commit
7931929a42
@ -694,12 +694,12 @@ static char * mg_strdup(const char *str) {
|
||||
return mg_strndup(str, strlen(str));
|
||||
}
|
||||
|
||||
static const char *mg_strcasestr(const char *big, const char *small) {
|
||||
int i, big_len = strlen(big), small_len = strlen(small);
|
||||
static const char *mg_strcasestr(const char *big_str, const char *small_str) {
|
||||
int i, big_len = strlen(big_str), small_len = strlen(small_str);
|
||||
|
||||
for (i = 0; i <= big_len - small_len; i++) {
|
||||
if (mg_strncasecmp(big + i, small, small_len) == 0) {
|
||||
return big + i;
|
||||
if (mg_strncasecmp(big_str + i, small_str, small_len) == 0) {
|
||||
return big_str + i;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user