#include <stdint.h>
#include <string.h>
-#ifndef STARTS_WITH
-#define STARTS_WITH(string, needle) (strncasecmp((string), (needle), strlen((needle))) == 0)
+#ifndef CS_STARTS_WITH
+#define CS_STARTS_WITH(string, needle) (strncmp((string), (needle), strlen((needle))) == 0)
#endif
/*
int buffer_len = strlen(format) + 1;
for (char *walk = format; *walk != '\0'; walk++) {
for (int i = 0; i < num; i++) {
- if (!STARTS_WITH(walk, placeholders[i].name))
+ if (!CS_STARTS_WITH(walk, placeholders[i].name))
continue;
buffer_len = buffer_len - strlen(placeholders[i].name) + strlen(placeholders[i].value);
bool matched = false;
for (int i = 0; i < num; i++) {
- if (!STARTS_WITH(walk, placeholders[i].name)) {
+ if (!CS_STARTS_WITH(walk, placeholders[i].name)) {
continue;
}