From f37484b45415d5bfd6aed51088d6af318dd6a665 Mon Sep 17 00:00:00 2001 From: brain Date: Mon, 30 Jul 2007 18:30:02 +0000 Subject: Replace blank error pages with an error page git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@7621 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/modules/m_httpd.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/modules/m_httpd.cpp b/src/modules/m_httpd.cpp index 631f89176..af8eac920 100644 --- a/src/modules/m_httpd.cpp +++ b/src/modules/m_httpd.cpp @@ -211,15 +211,14 @@ class HttpServerSocket : public InspSocket this->Write("HTTP/1.1 "+ConvToStr(response)+" "+Response(response)+"\r\nDate: "); this->Write(asctime(timeinfo)); if (extraheaders.empty()) - { this->Write("Content-Type: text/html\r\n"); - } else - { this->Write(extraheaders); - } this->Write("Server: InspIRCd/m_httpd.so/1.1\r\nContent-Length: "+ConvToStr(size)+ "\r\nConnection: close\r\n\r\n"); + if (response != 200) + this->Write("Server error "+ConvToStr(response)+": "+Response(response)+"
"+ + "Powered by InspIRCd\r\n"); } virtual bool OnDataReady() -- cgit v1.2.3