summaryrefslogtreecommitdiff
path: root/src/modules/m_setidle.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/m_setidle.cpp')
-rw-r--r--src/modules/m_setidle.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/modules/m_setidle.cpp b/src/modules/m_setidle.cpp
index 37984030b..8bca7000b 100644
--- a/src/modules/m_setidle.cpp
+++ b/src/modules/m_setidle.cpp
@@ -40,8 +40,8 @@ class CommandSetidle : public SplitCommand
CmdResult HandleLocal(LocalUser* user, const Params& parameters) CXX11_OVERRIDE
{
- int idle = InspIRCd::Duration(parameters[0]);
- if (idle < 1)
+ unsigned long idle;
+ if (!InspIRCd::Duration(parameters[0], idle))
{
user->WriteNumeric(ERR_INVALIDIDLETIME, "Invalid idle time.");
return CMD_FAILURE;