return;
/*
- * WARNING: nothing should come after this, as the user may be on a cull list to
- * be nuked next loop iteration. be sensible.
+ * WARNING: be careful, the user may be deleted soon
*/
CmdResult result = cm->second->Handle(command_p,items,user);
{
if (!user->muted)
{
- ServerInstance->Log(DEBUG,"C[%d] -> :%s %s",user->GetFd(), user->nick, buffer.c_str());
+ ServerInstance->Log(DEBUG,"C[%d] I :%s %s",user->GetFd(), user->nick, buffer.c_str());
this->ProcessCommand(user,buffer);
}
}
para.resize(128);
}
-bool CommandParser::FindSym(void** v, void* h)
+bool CommandParser::FindSym(void** v, void* h, const std::string &name)
{
*v = dlsym(h, "init_command");
const char* err = dlerror();
if (err && !(*v))
{
- ServerInstance->Log(SPARSE, "Error loading core command: %s\n", err);
+ ServerInstance->Log(SPARSE, "Error loading core command %s: %s\n", name.c_str(), err);
return false;
}
return true;
if (!h)
{
const char* n = dlerror();
- ServerInstance->Log(SPARSE, "Error loading core command: %s", n);
+ ServerInstance->Log(SPARSE, "Error loading core command %s: %s", name, n);
return n;
}
- if (this->FindSym((void **)&cmd_factory_func, h))
+ if (this->FindSym((void **)&cmd_factory_func, h, name))
{
command_t* newcommand = cmd_factory_func(ServerInstance);
this->CreateCommand(newcommand, h);