diff options
author | Nicolas "Pixel" Noble <pixel@nobis-crew.org> | 2013-08-13 06:50:21 +0200 |
---|---|---|
committer | Nicolas "Pixel" Noble <pixel@nobis-crew.org> | 2013-08-13 06:50:21 +0200 |
commit | 60589fcd0c7afc4f4cf0d832fd603ae75bc9c71a (patch) | |
tree | d7595339d4470c2580e413a6867ab9272254e833 /src/HttpServer.cc | |
parent | 735604976485ab69cd813d13ef53505bc454c201 (diff) |
Cleaning up the Handle API a bit.
Diffstat (limited to 'src/HttpServer.cc')
-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 140fe78..53e3da0 100644 --- a/src/HttpServer.cc +++ b/src/HttpServer.cc @@ -213,7 +213,7 @@ void Balau::HttpWorker::sendError(int error, const char * msg, const char * deta for (String & str : extraHeaders) headers += str + "\r\n"; headers += "\r\n"; - m_socket->forceWrite(headers); + m_socket->writeString(headers); if (m_socket->isClosed()) return; tpl->render(m_socket, &ctx); } else { @@ -231,7 +231,7 @@ void Balau::HttpWorker::sendError(int error, const char * msg, const char * deta for (String & str : extraHeaders) headers += str + "\r\n"; headers += "\r\n"; - m_socket->forceWrite(headers); + m_socket->writeString(headers); if (m_socket->isClosed()) return; m_socket->forceWrite(errorText->getBuffer(), length); } @@ -676,7 +676,7 @@ void Balau::HttpServer::Response::Flush() { String response(m_responseCode); headers->writeString(response); headers->writeString(" "); - headers->writeString(Http::getStatusMsg(m_responseCode), -1); + headers->writeString(Http::getStatusMsg(m_responseCode)); headers->writeString("\r\nContent-Type: "); headers->writeString(m_type); headers->writeString("\r\nContent-Length: "); |