summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/channels.cpp9
-rw-r--r--src/logger.cpp2
-rw-r--r--src/main.cpp5
3 files changed, 10 insertions, 6 deletions
diff --git a/src/channels.cpp b/src/channels.cpp
index 65298ad51..c39b7615b 100644
--- a/src/channels.cpp
+++ b/src/channels.cpp
@@ -175,7 +175,8 @@ void Channel::JoinUser(User *user)
}
}
- if (update_ts)
+ /* Update the TS, unless I'm joining a bot already */
+ if (update_ts && user->server != Me)
{
/* Send the updated TS */
if (!this->ci->bi || !this->FindUser(this->ci->bi))
@@ -831,9 +832,9 @@ void Channel::SetModes(BotInfo *bi, bool EnforceMLock, const char *cmodes, ...)
* @param mode the modes
* @param EnforceMLock true to enforce mlock
*/
-void Channel::SetModesInternal(User *setter, const Anope::string &modes, bool EnforceMLock)
+void Channel::SetModesInternal(User *setter, const Anope::string &mode, bool EnforceMLock)
{
- spacesepstream sep_modes(modes);
+ spacesepstream sep_modes(mode);
Anope::string m;
sep_modes.GetToken(m);
@@ -897,7 +898,7 @@ void Channel::SetModesInternal(User *setter, const Anope::string &modes, bool En
this->RemoveModeInternal(cm, token, EnforceMLock);
}
else
- Log() << "warning: Channel::SetModesInternal() recieved more modes requiring params than params, modes: " << modes;
+ Log() << "warning: Channel::SetModesInternal() recieved more modes requiring params than params, modes: " << mode;
}
if (setter)
diff --git a/src/logger.cpp b/src/logger.cpp
index 33ed3545a..3f1f35735 100644
--- a/src/logger.cpp
+++ b/src/logger.cpp
@@ -93,7 +93,7 @@ static inline Anope::string CreateLogName(const Anope::string &file, time_t t =
return "logs/" + file + "." + GetLogDate(t);
}
-LogFile::LogFile(const Anope::string &name) : filename(name), stream(name.c_str(), std::ios_base::out)
+LogFile::LogFile(const Anope::string &name) : filename(name), stream(name.c_str(), std::ios_base::out | std::ios_base::app)
{
}
diff --git a/src/main.cpp b/src/main.cpp
index 2f37b64d8..a1b02a496 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -277,6 +277,9 @@ void sighandler(int signum)
Log() << "Received " << strsignal(signum) << " signal (" << signum << "), exiting.";
+ if (Config->GlobalOnCycle)
+ oper_global("", "%s", Config->GlobalOnCycleMessage.c_str());
+
expire_all();
save_databases();
default:
@@ -489,7 +492,7 @@ int main(int ac, char **av, char **envp)
User *u = it->second;
++it;
- if (!findbot(u->nick))
+ if (u->server != Me)
delete u;
}