Skip to content
Browse files

Add Show command to identfile.

It should help us to debug that annoying bug of identfile aborting
connections...
  • Loading branch information...
1 parent 8f1027d commit ffabb169c1dba6da2fc7301a7f17a6c00e0b4b44 @DarthGandalf DarthGandalf committed with kylef Mar 15, 2012
Showing with 9 additions and 0 deletions.
  1. +9 −0 modules/identfile.cpp
View
9 modules/identfile.cpp
@@ -25,6 +25,7 @@ class CIdentFileModule : public CGlobalModule {
AddCommand("GetFormat", static_cast<CModCommand::ModCmdFunc>(&CIdentFileModule::GetFormat));
AddCommand("SetFormat", static_cast<CModCommand::ModCmdFunc>(&CIdentFileModule::SetFormat),
"<format>");
+ AddCommand("Show", static_cast<CModCommand::ModCmdFunc>(&CIdentFileModule::Show));
}
virtual ~CIdentFileModule() {
@@ -51,6 +52,14 @@ class CIdentFileModule : public CGlobalModule {
PutModule("Format would be expanded to: " + m_pUser->ExpandString(GetNV("Format")));
}
+ void Show(const CString& sLine) {
+ PutModule("m_pISpoofLockFile = " + CString((long long)m_pISpoofLockFile));
+ PutModule("m_pIRCSock = " + CString((long long)m_pIRCSock));
+ if (m_pIRCSock) {
+ PutModule("user = " + m_pIRCSock->GetUser()->GetUserName());
+ }
+ }
+
void OnModCommand(const CString& sCommand) {
if (m_pUser->IsAdmin()) {
HandleCommand(sCommand);

0 comments on commit ffabb16

Please sign in to comment.
Something went wrong with that request. Please try again.