diff options
author | Nicolas "Pixel" Noble <pixel@nobis-crew.org> | 2013-12-23 00:37:36 -0800 |
---|---|---|
committer | Nicolas "Pixel" Noble <pixel@nobis-crew.org> | 2013-12-23 00:37:36 -0800 |
commit | 61202b565e7c440cae443d71f78b6c506ab60f38 (patch) | |
tree | 0b8d8f51d0953229f43fb140c0183b852d053c64 /src | |
parent | e977ca1e5f6a10bab7af8b2736591f709783566f (diff) |
Apparently, the Connection header can be mixed cases.
Diffstat (limited to 'src')
-rw-r--r-- | src/HttpServer.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/HttpServer.cc b/src/HttpServer.cc index 921da3b..43594e9 100644 --- a/src/HttpServer.cc +++ b/src/HttpServer.cc @@ -436,15 +436,15 @@ bool Balau::HttpWorker::handleClient() { bool gotOne = false; for (auto j = connVals.begin(); j != connVals.end(); j++) { String t = j->trim(); - if ((t == "close") && (!gotOne)) { + if ((t.lower() == "close") && (!gotOne)) { gotOne = true; persistent = false; - } else if ((t == "keep-alive") && (!gotOne)) { + } else if ((t.lower() == "keep-alive") && (!gotOne)) { gotOne = true; persistent = true; } else if (t == "TE") { Printer::elog(E_HTTPSERVER, "%s got the 'TE' connection marker (which is still unknown)", m_name.to_charp()); - } else if (t == "Upgrade") { + } else if (t.lower() == "upgrade") { upgrade = true; persistent = true; } else { |