- unsigned int len = ConvToInt(parameter.substr(0, colon));
- unsigned int time = InspIRCd::Duration(duration);
- if (len == 0 || (len > maxlines && IS_LOCAL(source)))
+ unsigned int len = ConvToNum<unsigned int>(parameter.substr(0, colon));
+ unsigned long time;
+ if (!InspIRCd::Duration(duration, time) || len == 0 || (len > maxlines && IS_LOCAL(source)))