*/
#include "inspircd.h"
-#include "users.h"
-#include "channels.h"
-#include "modules.h"
/* $ModDesc: Povides support for the /DCCALLOW command */
{
this->source = "m_dccallow.so";
syntax = "{[+|-]<nick> <time>|HELP|LIST}";
+ /* XXX we need to fix this so it can work with translation stuff (i.e. move +- into a seperate param */
}
CmdResult Handle(const char **parameters, int pcnt, userrec *user)
long length;
if (pcnt < 2)
{
- length = ServerInstance->Duration(default_length.c_str());
+ length = ServerInstance->Duration(default_length);
}
else if (!atoi(parameters[1]))
{
virtual Version GetVersion()
{
- return Version(1,1,0,0,VF_COMMON|VF_VENDOR,API_VERSION);
+ return Version(1, 1, 0, 0, VF_COMMON | VF_VENDOR, API_VERSION);
}
};
-class ModuleDCCAllowFactory : public ModuleFactory
-{
- public:
- ModuleDCCAllowFactory()
- {
- }
-
- ~ModuleDCCAllowFactory()
- {
- }
-
- virtual Module * CreateModule(InspIRCd* Me)
- {
- return new ModuleDCCAllow(Me);
- }
-
-};
-
-extern "C" DllExport void * init_module( void )
-{
- return new ModuleDCCAllowFactory;
-}
+MODULE_INIT(ModuleDCCAllow)