mirror of
https://github.com/znc/znc.git
synced 2026-03-28 17:42:41 +01:00
sync from my branch rev 983 and 993:
- module api change, if module fails to load it can give back an useful error message - give a message when client doesnt supply a password when connecting - some minor cleanup git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@803 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
@@ -115,7 +115,7 @@ public:
|
||||
return true;
|
||||
}
|
||||
|
||||
virtual bool OnLoad(const CString& sArgStr) {
|
||||
virtual bool OnLoad(const CString& sArgStr, CString& sErrorMsg) {
|
||||
bool bSSL = false;
|
||||
bool bIPv6 = false;
|
||||
CString sArgs(sArgStr);
|
||||
@@ -165,8 +165,7 @@ public:
|
||||
|
||||
bool b = m_pManager->ListenHost(m_uPort, "WebAdmin::Listener", m_sListenHost, bSSL, SOMAXCONN, pListenSock, 0, bIPv6);
|
||||
if (!b) {
|
||||
printf("\n"); // dont mix it up with the 'loading module' message
|
||||
CUtils::PrintMessage("Error: " + CString(strerror(errno)), true);
|
||||
sErrorMsg = "Could not bind to port " + CString(m_uPort) + ": " + CString(strerror(errno));
|
||||
}
|
||||
return b;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user