diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-08-09 11:33:10 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-08-09 11:33:10 +0000 |
commit | 09afa5085614e0224a296abd082fce205003c3fe (patch) | |
tree | 444d54deea5f10e3045e0a8a016f9623499f513e /src/userprocess.cpp | |
parent | 6d4128715da39b1e097642a64ee0bd40586d9a38 (diff) |
ServerConfig extern moved into class InspIRCd
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4808 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/userprocess.cpp')
-rw-r--r-- | src/userprocess.cpp | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/src/userprocess.cpp b/src/userprocess.cpp index bf6a457a2..d262b5cab 100644 --- a/src/userprocess.cpp +++ b/src/userprocess.cpp @@ -63,7 +63,6 @@ extern std::vector<userrec*> local_users; extern InspSocket* socket_ref[MAX_DESCRIPTORS]; extern InspIRCd* ServerInstance; -extern ServerConfig *Config; extern userrec* fd_ref_table[MAX_DESCRIPTORS]; char data[65536]; @@ -79,14 +78,14 @@ void ProcessUser(userrec* cu) log(DEBUG,"Processing user with fd %d",cu->fd); - if (Config->GetIOHook(cu->GetPort())) + if (ServerInstance->Config->GetIOHook(cu->GetPort())) { int result2 = 0; int MOD_RESULT = 0; try { - MOD_RESULT = Config->GetIOHook(cu->GetPort())->OnRawSocketRead(cu->fd,data,65535,result2); + MOD_RESULT = ServerInstance->Config->GetIOHook(cu->GetPort())->OnRawSocketRead(cu->fd,data,65535,result2); log(DEBUG,"Data result returned by module: %d",MOD_RESULT); } catch (ModuleException& modexcept) @@ -170,14 +169,14 @@ void ProcessUser(userrec* cu) { WriteOpers("*** Excess flood from %s",current->GetIPString()); log(DEFAULT,"Excess flood from: %s",current->GetIPString()); - add_zline(120,Config->ServerName,"Flood from unregistered connection",current->GetIPString()); + add_zline(120,ServerInstance->Config->ServerName,"Flood from unregistered connection",current->GetIPString()); apply_lines(APPLY_ZLINES); } return; } - if (current->recvq.length() > (unsigned)Config->NetBufferSize) + if (current->recvq.length() > (unsigned)ServerInstance->Config->NetBufferSize) { if (current->registered == REG_ALL) { @@ -187,7 +186,7 @@ void ProcessUser(userrec* cu) { WriteOpers("*** Excess flood from %s",current->GetIPString()); log(DEFAULT,"Excess flood from: %s",current->GetIPString()); - add_zline(120,Config->ServerName,"Flood from unregistered connection",current->GetIPString()); + add_zline(120,ServerInstance->Config->ServerName,"Flood from unregistered connection",current->GetIPString()); apply_lines(APPLY_ZLINES); } @@ -221,7 +220,7 @@ void ProcessUser(userrec* cu) } else { - add_zline(120,Config->ServerName,"Flood from unregistered connection",current->GetIPString()); + add_zline(120,ServerInstance->Config->ServerName,"Flood from unregistered connection",current->GetIPString()); apply_lines(APPLY_ZLINES); } @@ -366,7 +365,7 @@ void DoBackgroundUserStuff(time_t TIME) curr->nping = TIME+curr->pingmax; continue; } - curr->Write("PING :%s",Config->ServerName); + curr->Write("PING :%s",ServerInstance->Config->ServerName); curr->lastping = 0; curr->nping = TIME+curr->pingmax; } |