summaryrefslogtreecommitdiff
path: root/modules/commands/cs_suspend.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'modules/commands/cs_suspend.cpp')
-rw-r--r--modules/commands/cs_suspend.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/modules/commands/cs_suspend.cpp b/modules/commands/cs_suspend.cpp
index 241d28453..bc122d048 100644
--- a/modules/commands/cs_suspend.cpp
+++ b/modules/commands/cs_suspend.cpp
@@ -73,7 +73,14 @@ class CommandCSSuspend : public Command
expiry.clear();
}
else
+ {
expiry_secs = Anope::DoTime(expiry);
+ if (expiry_secs == -1)
+ {
+ source.Reply(BAD_EXPIRY_TIME);
+ return;
+ }
+ }
if (Anope::ReadOnly)
source.Reply(READ_ONLY_MODE);