void _modinit(module_t *m) { if (ircd == NULL) { slog(LG_ERROR, "Module %s must be loaded after a protocol module.", m->name); m->mflags = MODTYPE_FAIL; return; } oldflag = ircd->uses_halfops; ircd->uses_halfops = false; update_chanacs_flags(); }
unsigned int flags_associate(unsigned char flag, unsigned int restrictflags, bool def, const char *name) { if (chanacs_flags[flag].value && chanacs_flags[flag].value != 0xFFFFFFFF) return 0; chanacs_flags[flag].value = flags_find_slot(); chanacs_flags[flag].restrictflags = restrictflags; chanacs_flags[flag].def = def; chanacs_flags[flag].name = name; update_chanacs_flags(); return chanacs_flags[flag].value; }
void _modinit(module_t *m) { if (ircd == NULL) { slog(LG_ERROR, "Module %s must be loaded after a protocol module.", m->name); m->mflags = MODTYPE_FAIL; return; } if (cnt.mychan > 0) { slog(LG_ERROR, "Module %s must be loaded from the configuration file, not via MODLOAD.", m->name); m->mflags = MODTYPE_FAIL; return; } oldflag = ircd->uses_protect; ircd->uses_protect = false; update_chanacs_flags(); }
void _moddeinit(module_unload_intent_t intent) { ircd->uses_protect = oldflag; update_chanacs_flags(); }
void _moddeinit() { ircd->uses_halfops = oldflag; update_chanacs_flags(); }