diff --git a/server/imserver/app.cc b/server/imserver/app.cc index c9906b3..467d705 100644 --- a/server/imserver/app.cc +++ b/server/imserver/app.cc @@ -26,6 +26,7 @@ #include "perfmonitor.h" #include "gamelog.h" #include "asynctaskmgr.h" +#include "guildmgr.h" #include "MSConnMgr.h" #include "IMConnMgr.h" @@ -106,6 +107,7 @@ bool App::Init(int argc, char* argv[]) DBHelper::Instance()->Init(); SyncHelper::Instance()->Init(); AsyncTaskMgr::Instance()->Init(); + GuildMgr::Instance()->Init(); a8::UdpLog::Instance()->Info("friend_imserver starting instance_id:%d pid:%d ", { @@ -140,6 +142,7 @@ bool App::Init(int argc, char* argv[]) void App::UnInit() { a8::XPrintf("friend_imserver terminating instance_id:%d pid:%d\n", {instance_id, getpid()}); + GuildMgr::Instance()->UnInit(); AsyncTaskMgr::Instance()->UnInit(); SyncHelper::Instance()->UnInit(); DBHelper::Instance()->UnInit(); @@ -424,6 +427,9 @@ void App::ProcessIMServerMsg(f8::MsgHdr& hdr) hdr.msgid); if (handler) { switch (handler->handlerid) { + case HID_GuildMgr: + ProcessNetMsg(handler, GuildMgr::Instance(), hdr); + break; case HID_IMListener: ProcessNetMsg(handler, IMListener::Instance(), hdr); break; diff --git a/server/imserver/synchelper.cc b/server/imserver/synchelper.cc index 0bf71a5..46219f8 100644 --- a/server/imserver/synchelper.cc +++ b/server/imserver/synchelper.cc @@ -189,7 +189,7 @@ void SyncHelper::SendIMConnMsg(int instance_id, int msgid, ::google::protobuf::M } App::Instance()->AddSocketMsg ( - SF_IMConn, + SF_IMServer, 0, 0, msgid,