summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/channels.cpp4
-rw-r--r--src/mail.cpp4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/channels.cpp b/src/channels.cpp
index 65668a6d6..aa2e0affc 100644
--- a/src/channels.cpp
+++ b/src/channels.cpp
@@ -1145,7 +1145,7 @@ void do_join(const Anope::string &source, int ac, const char **av)
/* Join came with a TS */
if (ac == 2)
{
- time_t ts = Anope::string(av[1]).is_number_only() ? convertTo<time_t>(av[1]) : 0;
+ time_t ts = Anope::string(av[1]).is_pos_number_only() ? convertTo<time_t>(av[1]) : 0;
/* Their time is older, we lose */
if (chan->creation_time > ts)
@@ -1309,7 +1309,7 @@ void do_topic(const Anope::string &source, int ac, const char **av)
{
Channel *c = findchan(av[0]);
ChannelInfo *ci;
- time_t topic_time = Anope::string(av[2]).is_number_only() ? convertTo<time_t>(av[2]) : 0;
+ time_t topic_time = Anope::string(av[2]).is_pos_number_only() ? convertTo<time_t>(av[2]) : 0;
if (!c)
{
diff --git a/src/mail.cpp b/src/mail.cpp
index 1cfdd6c09..354c7e2e7 100644
--- a/src/mail.cpp
+++ b/src/mail.cpp
@@ -40,7 +40,7 @@ bool Mail(User *u, NickRequest *nr, const Anope::string &service, const Anope::s
if (!Config->UseMail)
notice_lang(service, u, MAIL_DISABLED);
else if (t - u->lastmail < Config->MailDelay)
- notice_lang(service, u, MAIL_DELAYED, t - u->lastmail);
+ notice_lang(service, u, MAIL_DELAYED, Config->MailDelay - t - u->lastmail);
else if (nr->email.empty())
notice_lang(service, u, MAIL_INVALID, nr->nick.c_str());
else
@@ -63,7 +63,7 @@ bool Mail(User *u, NickCore *nc, const Anope::string &service, const Anope::stri
if (!Config->UseMail)
notice_lang(service, u, MAIL_DISABLED);
else if (t - u->lastmail < Config->MailDelay)
- notice_lang(service, u, MAIL_DELAYED, t - u->lastmail);
+ notice_lang(service, u, MAIL_DELAYED, Config->MailDelay - t - u->lastmail);
else if (nc->email.empty())
notice_lang(service, u, MAIL_INVALID, nc->display.c_str());
else