diff options
| author | 2020-04-09 00:14:59 +0100 | |
|---|---|---|
| committer | 2020-04-09 00:14:59 +0100 | |
| commit | 0e7e1ea3935e48a5093be4ccf2371a344f30bba0 (patch) | |
| tree | 86b4fa350cd4d6a6cb183b9bd918c0c74f230d93 /src/modules/m_httpd.cpp | |
| parent | Add a way to disable using environment variables in included files. (diff) | |
| download | inspircd++-0e7e1ea3935e48a5093be4ccf2371a344f30bba0.tar.gz inspircd++-0e7e1ea3935e48a5093be4ccf2371a344f30bba0.tar.bz2 inspircd++-0e7e1ea3935e48a5093be4ccf2371a344f30bba0.zip | |
Improve the logging of the httpd module.
Diffstat (limited to 'src/modules/m_httpd.cpp')
| -rw-r--r-- | src/modules/m_httpd.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/modules/m_httpd.cpp b/src/modules/m_httpd.cpp index 978a60ab7..7b2487d1c 100644 --- a/src/modules/m_httpd.cpp +++ b/src/modules/m_httpd.cpp @@ -95,6 +95,7 @@ class HttpServerSocket : public BufferedSocket, public Timer, public insp::intru { if (!messagecomplete) { + ServerInstance->Logs->Log(MODNAME, LOG_DEBUG, "HTTP socket %d timed out", GetFd()); Close(); return false; } @@ -229,6 +230,8 @@ class HttpServerSocket : public BufferedSocket, public Timer, public insp::intru // IOHook may have errored if (!getError().empty()) { + ServerInstance->Logs->Log(MODNAME, LOG_DEBUG, "HTTP socket %d encountered a hook error: %s", + GetFd(), getError().c_str()); Close(); return; } @@ -254,8 +257,10 @@ class HttpServerSocket : public BufferedSocket, public Timer, public insp::intru ServerInstance->GlobalCulls.AddItem(this); } - void OnError(BufferedSocketError) CXX11_OVERRIDE + void OnError(BufferedSocketError err) CXX11_OVERRIDE { + ServerInstance->Logs->Log(MODNAME, LOG_DEBUG, "HTTP socket %d encountered an error: %d - %s", + GetFd(), err, getError().c_str()); Close(); } |
