Skip to content

Commit 20b664c

Browse files
Merge branch 'main' into remove-memchr
2 parents a4fad7d + 20ce691 commit 20b664c

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/AsyncWebHeader.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,14 @@ const AsyncWebHeader AsyncWebHeader::parse(const char *data) {
1515
if (strchr(data, '\n') || strchr(data, '\r')) {
1616
return AsyncWebHeader(); // Invalid header format
1717
}
18-
char *colon = strchr(data, ':');
18+
const char *colon = strchr(data, ':');
1919
if (!colon) {
2020
return AsyncWebHeader(); // separator not found
2121
}
2222
if (colon == data) {
2323
return AsyncWebHeader(); // Header name cannot be empty
2424
}
25-
char *startOfValue = colon + 1; // Skip the colon
25+
const char *startOfValue = colon + 1; // Skip the colon
2626
// skip one optional whitespace after the colon
2727
if (*startOfValue == ' ') {
2828
startOfValue++;

0 commit comments

Comments
 (0)