diff --git a/service/http_header.h b/service/http_header.h index ed29507e..25f1b73f 100644 --- a/service/http_header.h +++ b/service/http_header.h @@ -7,6 +7,10 @@ #pragma once +#include + +#include + #include #include #include @@ -72,8 +76,17 @@ struct HttpHeader { ssize_t contentLength; bool isChunked; + struct NoCaseEqual { + typedef const std::string & String; + bool operator() (String first, String second) const { + return !strcasecmp(first.c_str(), second.c_str()); + } + }; + + typedef std::map HeaderMap; + // The rest of the headers are here - std::map headers; + HeaderMap headers; std::string getHeader(const std::string & key) const {