diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/init.cpp | 6 | ||||
-rw-r--r-- | src/main.cpp | 7 |
2 files changed, 6 insertions, 7 deletions
diff --git a/src/init.cpp b/src/init.cpp index 49d9759a8..4cff3fc91 100644 --- a/src/init.cpp +++ b/src/init.cpp @@ -21,7 +21,11 @@ void introduce_user(const Anope::string &user) time_t now = Anope::CurTime; static time_t lasttime = now - 4; if (lasttime >= now - 3) - throw FatalException("introduce_user loop detected"); + { + quitmsg = "introduce_user loop detected"; + quitting = true; + return; + } lasttime = now; User *u = finduser(user); diff --git a/src/main.cpp b/src/main.cpp index 875e4eeb6..3730c60ea 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -68,9 +68,6 @@ time_t Anope::CurTime = time(NULL); /******** Local variables! ********/ -/* Set to 1 after we've set everything up */ -static bool started = false; - /*************************************************************************/ class UpdateTimer : public Timer @@ -118,7 +115,7 @@ class UplinkSocket : public ConnectionSocket ~UplinkSocket() { - if (Me && !Me->GetLinks().empty() && Me->GetLinks()[0]->IsSynced()) + if (ircdproto && Me && !Me->GetLinks().empty() && Me->GetLinks()[0]->IsSynced()) { FOREACH_MOD(I_OnServerDisconnect, OnServerDisconnect()); @@ -354,8 +351,6 @@ int main(int ac, char **av, char **envp) return_code = -1; } - started = true; - /* Set up timers */ time_t last_check = Anope::CurTime; UpdateTimer updateTimer(Config->UpdateTimeout); |