diff --git a/src/modules/antimixedutf8.c b/src/modules/antimixedutf8.c index 8654e4d46..30aefd66b 100644 --- a/src/modules/antimixedutf8.c +++ b/src/modules/antimixedutf8.c @@ -60,8 +60,8 @@ struct { static void free_config(void); static void init_config(void); -DLLFUNC int antimixedutf8_config_test(ConfigFile *, ConfigEntry *, int, int *); -DLLFUNC int antimixedutf8_config_run(ConfigFile *, ConfigEntry *, int); +int antimixedutf8_config_test(ConfigFile *, ConfigEntry *, int, int *); +int antimixedutf8_config_run(ConfigFile *, ConfigEntry *, int); #define SCRIPT_UNDEFINED 0 #define SCRIPT_LATIN 1 @@ -260,7 +260,7 @@ static void free_config(void) memset(&cfg, 0, sizeof(cfg)); /* needed! */ } -DLLFUNC int antimixedutf8_config_test(ConfigFile *cf, ConfigEntry *ce, int type, int *errs) +int antimixedutf8_config_test(ConfigFile *cf, ConfigEntry *ce, int type, int *errs) { int errors = 0; ConfigEntry *cep; @@ -321,7 +321,7 @@ DLLFUNC int antimixedutf8_config_test(ConfigFile *cf, ConfigEntry *ce, int type, return errors ? -1 : 1; } -DLLFUNC int antimixedutf8_config_run(ConfigFile *cf, ConfigEntry *ce, int type) +int antimixedutf8_config_run(ConfigFile *cf, ConfigEntry *ce, int type) { ConfigEntry *cep; diff --git a/src/modules/chanmodes/censor.c b/src/modules/chanmodes/censor.c index e353a5023..8ac8edd0a 100644 --- a/src/modules/chanmodes/censor.c +++ b/src/modules/chanmodes/censor.c @@ -24,8 +24,8 @@ char *censor_pre_chanmsg(aClient *sptr, aChannel *chptr, char *text, int notice) char *censor_pre_local_part(aClient *sptr, aChannel *chptr, char *text); char *censor_pre_local_quit(aClient *sptr, char *text); -DLLFUNC int censor_config_test(ConfigFile *, ConfigEntry *, int, int *); -DLLFUNC int censor_config_run(ConfigFile *, ConfigEntry *, int); +int censor_config_test(ConfigFile *, ConfigEntry *, int, int *); +int censor_config_run(ConfigFile *, ConfigEntry *, int); ModuleInfo *ModInfo = NULL; @@ -83,7 +83,7 @@ MOD_UNLOAD(censor) return MOD_SUCCESS; } -DLLFUNC int censor_config_test(ConfigFile *cf, ConfigEntry *ce, int type, int *errs) +int censor_config_test(ConfigFile *cf, ConfigEntry *ce, int type, int *errs) { int errors = 0; ConfigEntry *cep; @@ -203,7 +203,7 @@ DLLFUNC int censor_config_test(ConfigFile *cf, ConfigEntry *ce, int type, int *e } -DLLFUNC int censor_config_run(ConfigFile *cf, ConfigEntry *ce, int type) +int censor_config_run(ConfigFile *cf, ConfigEntry *ce, int type) { ConfigEntry *cep, *word = NULL; ConfigItem_badword *ca; diff --git a/src/modules/chanmodes/delayjoin.c b/src/modules/chanmodes/delayjoin.c index 8619a1542..10d9bbe08 100644 --- a/src/modules/chanmodes/delayjoin.c +++ b/src/modules/chanmodes/delayjoin.c @@ -23,15 +23,15 @@ static Cmode *CmodePostDelayed = NULL; static Cmode_t EXTMODE_DELAYED; static Cmode_t EXTMODE_POST_DELAYED; -DLLFUNC int visible_in_channel( aClient *cptr, aChannel *chptr); -DLLFUNC int moded_check_part( aClient *cptr, aChannel *chptr); -DLLFUNC int moded_join(aClient *cptr, aChannel *chptr); -DLLFUNC int moded_part(aClient *cptr, aClient *sptr, aChannel *chptr, char *comment); -DLLFUNC int deny_all(aClient *cptr, aChannel *chptr, char mode, char *para, int checkt, int what); -DLLFUNC int moded_kick(aClient *cptr, aClient *sptr, aClient *acptr, aChannel *chptr, char *comment); -DLLFUNC int moded_chanmode(aClient *cptr, aClient *sptr, aChannel *chptr, +int visible_in_channel( aClient *cptr, aChannel *chptr); +int moded_check_part( aClient *cptr, aChannel *chptr); +int moded_join(aClient *cptr, aChannel *chptr); +int moded_part(aClient *cptr, aClient *sptr, aChannel *chptr, char *comment); +int deny_all(aClient *cptr, aChannel *chptr, char mode, char *para, int checkt, int what); +int moded_kick(aClient *cptr, aClient *sptr, aClient *acptr, aChannel *chptr, char *comment); +int moded_chanmode(aClient *cptr, aClient *sptr, aChannel *chptr, char *modebuf, char *parabuf, time_t sendts, int samode); -DLLFUNC char *moded_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice); +char *moded_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice); char *moded_serialize(ModData *m); void moded_unserialize(char *str, ModData *m); @@ -95,13 +95,13 @@ MOD_UNLOAD(delayjoin) return MOD_SUCCESS; } -DLLFUNC void set_post_delayed(aChannel *chptr) +void set_post_delayed(aChannel *chptr) { chptr->mode.extmode |= EXTMODE_POST_DELAYED; sendto_channel_butserv(chptr, &me, ":%s MODE %s +d", me.name, chptr->chname); } -DLLFUNC void clear_post_delayed(aChannel *chptr) +void clear_post_delayed(aChannel *chptr) { chptr->mode.extmode &= ~EXTMODE_POST_DELAYED; sendto_channel_butserv(chptr, &me, ":%s MODE %s -d", me.name, chptr->chname); @@ -130,7 +130,7 @@ bool moded_user_invisible(aClient *cptr, aChannel *chptr) return moded_member_invisible(find_member_link(chptr->members, cptr),chptr); } -DLLFUNC bool channel_has_invisible_users(aChannel *chptr) +bool channel_has_invisible_users(aChannel *chptr) { Member* i; for (i = chptr->members; i; i = i->next) @@ -143,21 +143,21 @@ DLLFUNC bool channel_has_invisible_users(aChannel *chptr) return false; } -DLLFUNC bool channel_is_post_delayed(aChannel *chptr) +bool channel_is_post_delayed(aChannel *chptr) { if (chptr->mode.extmode & EXTMODE_POST_DELAYED) return true; return false; } -DLLFUNC bool channel_is_delayed(aChannel *chptr) +bool channel_is_delayed(aChannel *chptr) { if (chptr->mode.extmode & EXTMODE_DELAYED) return true; return false; } -DLLFUNC void clear_user_invisible(aChannel *chptr, aClient *sptr) +void clear_user_invisible(aChannel *chptr, aClient *sptr) { Member *i; ModDataInfo *md; @@ -194,7 +194,7 @@ DLLFUNC void clear_user_invisible(aChannel *chptr, aClient *sptr) } } -DLLFUNC void clear_user_invisible_announce(aChannel *chptr, aClient *sptr) +void clear_user_invisible_announce(aChannel *chptr, aClient *sptr) { Member *i; char joinbuf[512]; @@ -223,7 +223,7 @@ DLLFUNC void clear_user_invisible_announce(aChannel *chptr, aClient *sptr) } } -DLLFUNC void set_user_invisible(aChannel *chptr, aClient *sptr) +void set_user_invisible(aChannel *chptr, aClient *sptr) { Member *m = find_member_link(chptr->members,sptr); ModDataInfo *md; @@ -240,19 +240,19 @@ DLLFUNC void set_user_invisible(aChannel *chptr, aClient *sptr) } -DLLFUNC int deny_all(aClient *cptr, aChannel *chptr, char mode, char *para, int checkt, int what) +int deny_all(aClient *cptr, aChannel *chptr, char mode, char *para, int checkt, int what) { return EX_ALWAYS_DENY; } -DLLFUNC int visible_in_channel(aClient *cptr, aChannel *chptr) +int visible_in_channel(aClient *cptr, aChannel *chptr) { return channel_is_delayed(chptr) && moded_user_invisible(cptr,chptr); } -DLLFUNC int moded_join(aClient *cptr, aChannel *chptr) +int moded_join(aClient *cptr, aChannel *chptr) { if (channel_is_delayed(chptr)) set_user_invisible(chptr,cptr); @@ -260,7 +260,7 @@ DLLFUNC int moded_join(aClient *cptr, aChannel *chptr) return 0; } -DLLFUNC int moded_part(aClient *cptr, aClient *sptr, aChannel *chptr, char *comment) +int moded_part(aClient *cptr, aClient *sptr, aChannel *chptr, char *comment) { if (channel_is_delayed(chptr) || channel_is_post_delayed(chptr)) clear_user_invisible(chptr,cptr); @@ -268,7 +268,7 @@ DLLFUNC int moded_part(aClient *cptr, aClient *sptr, aChannel *chptr, char *comm return 0; } -DLLFUNC int moded_kick(aClient *cptr, aClient *sptr, aClient *acptr, aChannel *chptr, char *comment) +int moded_kick(aClient *cptr, aClient *sptr, aClient *acptr, aChannel *chptr, char *comment) { if (channel_is_delayed(chptr) || channel_is_post_delayed(chptr)) if (moded_user_invisible(acptr, chptr)) @@ -278,7 +278,7 @@ DLLFUNC int moded_kick(aClient *cptr, aClient *sptr, aClient *acptr, aChannel *c } -DLLFUNC int moded_chanmode(aClient *cptr, aClient *sptr, aChannel *chptr, +int moded_chanmode(aClient *cptr, aClient *sptr, aChannel *chptr, char *modebuf, char *parabuf, time_t sendts, int samode) { // Handle case where we just unset +D but have invisible users @@ -356,7 +356,7 @@ DLLFUNC int moded_chanmode(aClient *cptr, aClient *sptr, aChannel *chptr, return 0; } -DLLFUNC char *moded_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice) +char *moded_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice) { if ((channel_is_delayed(chptr) || channel_is_post_delayed(chptr)) && (moded_user_invisible(sptr,chptr))) diff --git a/src/modules/chanmodes/issecure.c b/src/modules/chanmodes/issecure.c index d16b072c0..285c366a1 100644 --- a/src/modules/chanmodes/issecure.c +++ b/src/modules/chanmodes/issecure.c @@ -43,11 +43,11 @@ Cmode_t EXTCMODE_ISSECURE; int IsSecureJoin(aChannel *chptr); int modeZ_is_ok(aClient *sptr, aChannel *chptr, char mode, char *para, int checkt, int what); -DLLFUNC int issecure_join(aClient *cptr, aClient *sptr, aChannel *chptr, char *parv[]); -DLLFUNC int issecure_part(aClient *cptr, aClient *sptr, aChannel *chptr, char *comment); -DLLFUNC int issecure_quit(aClient *acptr, char *comment); -DLLFUNC int issecure_kick(aClient *cptr, aClient *sptr, aClient *acptr, aChannel *chptr, char *comment); -DLLFUNC int issecure_chanmode(aClient *cptr, aClient *sptr, aChannel *chptr, +int issecure_join(aClient *cptr, aClient *sptr, aChannel *chptr, char *parv[]); +int issecure_part(aClient *cptr, aClient *sptr, aChannel *chptr, char *comment); +int issecure_quit(aClient *acptr, char *comment); +int issecure_kick(aClient *cptr, aClient *sptr, aClient *acptr, aChannel *chptr, char *comment); +int issecure_chanmode(aClient *cptr, aClient *sptr, aChannel *chptr, char *modebuf, char *parabuf, time_t sendts, int samode); @@ -178,7 +178,7 @@ void issecure_set(aChannel *chptr, aClient *sptr, int notice) * so while they can be written shorter, they would only take longer to execute! */ -DLLFUNC int issecure_join(aClient *cptr, aClient *sptr, aChannel *chptr, char *parv[]) +int issecure_join(aClient *cptr, aClient *sptr, aChannel *chptr, char *parv[]) { /* Check only if chan already +zZ and the user joining is insecure (no need to count) */ if (IsSecureJoin(chptr) && IsSecureChanIndicated(chptr) && !IsSecureConnect(sptr) && !IsULine(sptr)) @@ -191,7 +191,7 @@ DLLFUNC int issecure_join(aClient *cptr, aClient *sptr, aChannel *chptr, char *p return 0; } -DLLFUNC int issecure_part(aClient *cptr, aClient *sptr, aChannel *chptr, char *comment) +int issecure_part(aClient *cptr, aClient *sptr, aChannel *chptr, char *comment) { /* Only care if chan is +z-Z and the user leaving is insecure, then count */ if (IsSecureJoin(chptr) && !IsSecureChanIndicated(chptr) && !IsSecureConnect(sptr) && @@ -200,7 +200,7 @@ DLLFUNC int issecure_part(aClient *cptr, aClient *sptr, aChannel *chptr, char *c return 0; } -DLLFUNC int issecure_quit(aClient *sptr, char *comment) +int issecure_quit(aClient *sptr, char *comment) { Membership *membership; aChannel *chptr; @@ -216,7 +216,7 @@ aChannel *chptr; return 0; } -DLLFUNC int issecure_kick(aClient *cptr, aClient *sptr, aClient *victim, aChannel *chptr, char *comment) +int issecure_kick(aClient *cptr, aClient *sptr, aClient *victim, aChannel *chptr, char *comment) { /* Identical to part&quit, except we care about 'victim' and not 'sptr' */ if (IsSecureJoin(chptr) && !IsSecureChanIndicated(chptr) && @@ -225,7 +225,7 @@ DLLFUNC int issecure_kick(aClient *cptr, aClient *sptr, aClient *victim, aChanne return 0; } -DLLFUNC int issecure_chanmode(aClient *cptr, aClient *sptr, aChannel *chptr, +int issecure_chanmode(aClient *cptr, aClient *sptr, aChannel *chptr, char *modebuf, char *parabuf, time_t sendts, int samode) { if (!strchr(modebuf, 'z')) diff --git a/src/modules/chanmodes/nocolor.c b/src/modules/chanmodes/nocolor.c index a2c0d882c..fddb7097a 100644 --- a/src/modules/chanmodes/nocolor.c +++ b/src/modules/chanmodes/nocolor.c @@ -34,9 +34,9 @@ Cmode_t EXTCMODE_NOCOLOR; #define IsNoColor(chptr) (chptr->mode.extmode & EXTCMODE_NOCOLOR) -DLLFUNC char *nocolor_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice); -DLLFUNC char *nocolor_prelocalpart(aClient *sptr, aChannel *chptr, char *comment); -DLLFUNC char *nocolor_prelocalquit(aClient *sptr, char *comment); +char *nocolor_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice); +char *nocolor_prelocalpart(aClient *sptr, aChannel *chptr, char *comment); +char *nocolor_prelocalquit(aClient *sptr, char *comment); MOD_TEST(nocolor) { @@ -84,7 +84,7 @@ static int IsUsingColor(char *s) return 0; } -DLLFUNC char *nocolor_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice) +char *nocolor_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice) { Hook *h; int i; @@ -112,7 +112,7 @@ DLLFUNC char *nocolor_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int return text; } -DLLFUNC char *nocolor_prelocalpart(aClient *sptr, aChannel *chptr, char *comment) +char *nocolor_prelocalpart(aClient *sptr, aChannel *chptr, char *comment) { if (!comment) return NULL; @@ -134,7 +134,7 @@ static int IsAnyChannelNoColor(aClient *sptr) return 0; } -DLLFUNC char *nocolor_prelocalquit(aClient *sptr, char *comment) +char *nocolor_prelocalquit(aClient *sptr, char *comment) { if (!comment) return NULL; diff --git a/src/modules/chanmodes/noctcp.c b/src/modules/chanmodes/noctcp.c index b580f994d..13249c9b9 100644 --- a/src/modules/chanmodes/noctcp.c +++ b/src/modules/chanmodes/noctcp.c @@ -34,7 +34,7 @@ Cmode_t EXTCMODE_NOCTCP; #define IsNoCTCP(chptr) (chptr->mode.extmode & EXTCMODE_NOCTCP) -DLLFUNC char *noctcp_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice); +char *noctcp_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice); MOD_TEST(noctcp) { @@ -78,7 +78,7 @@ static int IsACTCP(char *s) return 0; } -DLLFUNC char *noctcp_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice) +char *noctcp_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice) { if (MyClient(sptr) && IsNoCTCP(chptr) && IsACTCP(text)) { diff --git a/src/modules/chanmodes/noinvite.c b/src/modules/chanmodes/noinvite.c index a659c9b79..fc571f9fd 100644 --- a/src/modules/chanmodes/noinvite.c +++ b/src/modules/chanmodes/noinvite.c @@ -34,8 +34,8 @@ Cmode_t EXTCMODE_NOINVITE; #define IsNoInvite(chptr) (chptr->mode.extmode & EXTCMODE_NOINVITE) -DLLFUNC int noinvite_pre_knock(aClient *sptr, aChannel *chptr); -DLLFUNC int noinvite_pre_invite(aClient *sptr, aClient *acptr, aChannel *chptr, int *override); +int noinvite_pre_knock(aClient *sptr, aChannel *chptr); +int noinvite_pre_invite(aClient *sptr, aClient *acptr, aChannel *chptr, int *override); MOD_TEST(noinvite) { @@ -70,7 +70,7 @@ MOD_UNLOAD(noinvite) } -DLLFUNC int noinvite_pre_knock(aClient *sptr, aChannel *chptr) +int noinvite_pre_knock(aClient *sptr, aChannel *chptr) { if (MyClient(sptr) && IsNoInvite(chptr)) { @@ -84,7 +84,7 @@ DLLFUNC int noinvite_pre_knock(aClient *sptr, aChannel *chptr) return HOOK_CONTINUE; } -DLLFUNC int noinvite_pre_invite(aClient *sptr, aClient *acptr, aChannel *chptr, int *override) +int noinvite_pre_invite(aClient *sptr, aClient *acptr, aChannel *chptr, int *override) { if (MyClient(sptr) && IsNoInvite(chptr)) { diff --git a/src/modules/chanmodes/noknock.c b/src/modules/chanmodes/noknock.c index e2697bdb4..3077df6be 100644 --- a/src/modules/chanmodes/noknock.c +++ b/src/modules/chanmodes/noknock.c @@ -32,9 +32,9 @@ Cmode_t EXTCMODE_NOKNOCK; #define IsNoKnock(chptr) (chptr->mode.extmode & EXTCMODE_NOKNOCK) -DLLFUNC int noknock_check (aClient *sptr, aChannel *chptr); -DLLFUNC int noknock_mode_allow(aClient *cptr, aChannel *chptr, char mode, char *para, int checkt, int what); -DLLFUNC int noknock_mode_del (aChannel *chptr, int modeChar); +int noknock_check (aClient *sptr, aChannel *chptr); +int noknock_mode_allow(aClient *cptr, aChannel *chptr, char mode, char *para, int checkt, int what); +int noknock_mode_del (aChannel *chptr, int modeChar); MOD_TEST(noknock) { @@ -70,7 +70,7 @@ MOD_UNLOAD(noctcp) } -DLLFUNC int noknock_check (aClient *sptr, aChannel *chptr) +int noknock_check (aClient *sptr, aChannel *chptr) { if (MyClient(sptr) && IsNoKnock(chptr)) { @@ -83,7 +83,7 @@ DLLFUNC int noknock_check (aClient *sptr, aChannel *chptr) return HOOK_CONTINUE; } -DLLFUNC int noknock_mode_del (aChannel *chptr, int modeChar) +int noknock_mode_del (aChannel *chptr, int modeChar) { // Remove noknock when we're removing invite only if (modeChar == 'i') @@ -92,7 +92,7 @@ DLLFUNC int noknock_mode_del (aChannel *chptr, int modeChar) return 0; } -DLLFUNC int noknock_mode_allow(aClient *cptr, aChannel *chptr, char mode, char *para, int checkt, int what) +int noknock_mode_allow(aClient *cptr, aChannel *chptr, char mode, char *para, int checkt, int what) { if (!(chptr->mode.mode & MODE_INVITEONLY)) diff --git a/src/modules/chanmodes/nonickchange.c b/src/modules/chanmodes/nonickchange.c index da9a2e1fe..83b967db0 100644 --- a/src/modules/chanmodes/nonickchange.c +++ b/src/modules/chanmodes/nonickchange.c @@ -33,7 +33,7 @@ Cmode_t EXTCMODE_NONICKCHANGE; #define IsNoNickChange(chptr) (chptr->mode.extmode & EXTCMODE_NONICKCHANGE) -DLLFUNC int nonickchange_check (aClient *sptr, aChannel *chptr); +int nonickchange_check (aClient *sptr, aChannel *chptr); MOD_TEST(nonickchange) { @@ -67,7 +67,7 @@ MOD_UNLOAD(nonickchange) return MOD_SUCCESS; } -DLLFUNC int nonickchange_check (aClient *sptr, aChannel *chptr) +int nonickchange_check (aClient *sptr, aChannel *chptr) { if (!IsOper(sptr) && !IsULine(sptr) && IsNoNickChange(chptr) diff --git a/src/modules/chanmodes/operonly.c b/src/modules/chanmodes/operonly.c index 14cbd9d74..43c2a1c9e 100644 --- a/src/modules/chanmodes/operonly.c +++ b/src/modules/chanmodes/operonly.c @@ -32,10 +32,10 @@ ModuleHeader MOD_HEADER(operonly) Cmode_t EXTCMODE_OPERONLY; -DLLFUNC int operonly_require_oper(aClient *cptr, aChannel *chptr, char mode, char *para, int checkt, int what); -DLLFUNC int operonly_check (aClient *cptr, aChannel *chptr, char *key, char *parv[]); -DLLFUNC int operonly_topic_allow (aClient *sptr, aChannel *chptr); -DLLFUNC int operonly_check_ban(aClient *cptr, aChannel *chptr); +int operonly_require_oper(aClient *cptr, aChannel *chptr, char mode, char *para, int checkt, int what); +int operonly_check (aClient *cptr, aChannel *chptr, char *key, char *parv[]); +int operonly_topic_allow (aClient *sptr, aChannel *chptr); +int operonly_check_ban(aClient *cptr, aChannel *chptr); MOD_TEST(operonly) { @@ -71,14 +71,14 @@ MOD_UNLOAD(noctcp) return MOD_SUCCESS; } -DLLFUNC int operonly_check (aClient *cptr, aChannel *chptr, char *key, char *parv[]) +int operonly_check (aClient *cptr, aChannel *chptr, char *key, char *parv[]) { if ((chptr->mode.extmode & EXTCMODE_OPERONLY) && !ValidatePermissionsForPath("channel:operonly:join",cptr,NULL,chptr,NULL)) return ERR_OPERONLY; return 0; } -DLLFUNC int operonly_check_ban(aClient *cptr, aChannel *chptr) +int operonly_check_ban(aClient *cptr, aChannel *chptr) { if ((chptr->mode.extmode & EXTCMODE_OPERONLY) && !ValidatePermissionsForPath("channel:operonly:ban",cptr,NULL,NULL,NULL)) @@ -87,7 +87,7 @@ DLLFUNC int operonly_check_ban(aClient *cptr, aChannel *chptr) return HOOK_CONTINUE; } -DLLFUNC int operonly_topic_allow (aClient *sptr, aChannel *chptr) +int operonly_topic_allow (aClient *sptr, aChannel *chptr) { if (chptr->mode.extmode & EXTCMODE_OPERONLY && !ValidatePermissionsForPath("channel:operonly:topic",sptr,NULL,chptr,NULL)) return HOOK_DENY; @@ -95,7 +95,7 @@ DLLFUNC int operonly_topic_allow (aClient *sptr, aChannel *chptr) return HOOK_CONTINUE; } -DLLFUNC int operonly_require_oper(aClient *cptr, aChannel *chptr, char mode, char *para, int checkt, int what) +int operonly_require_oper(aClient *cptr, aChannel *chptr, char mode, char *para, int checkt, int what) { if (!MyClient(cptr) || ValidatePermissionsForPath("channel:operonly:set",cptr,NULL,chptr,NULL)) return EX_ALLOW; diff --git a/src/modules/chanmodes/regonly.c b/src/modules/chanmodes/regonly.c index fafe9a97b..8bb9ca8ba 100644 --- a/src/modules/chanmodes/regonly.c +++ b/src/modules/chanmodes/regonly.c @@ -33,7 +33,7 @@ Cmode_t EXTCMODE_REGONLY; #define IsRegOnly(chptr) (chptr->mode.extmode & EXTCMODE_REGONLY) -DLLFUNC int regonly_check (aClient *cptr, aChannel *chptr, char *key, char *parv[]); +int regonly_check (aClient *cptr, aChannel *chptr, char *key, char *parv[]); MOD_TEST(regonly) @@ -68,7 +68,7 @@ MOD_UNLOAD(regonly) return MOD_SUCCESS; } -DLLFUNC int regonly_check (aClient *cptr, aChannel *chptr, char *key, char *parv[]) +int regonly_check (aClient *cptr, aChannel *chptr, char *key, char *parv[]) { if (IsRegOnly(chptr) && !IsLoggedIn(cptr)) return ERR_NEEDREGGEDNICK; diff --git a/src/modules/chanmodes/regonlyspeak.c b/src/modules/chanmodes/regonlyspeak.c index b783503dd..1416d9a8e 100644 --- a/src/modules/chanmodes/regonlyspeak.c +++ b/src/modules/chanmodes/regonlyspeak.c @@ -34,8 +34,8 @@ static char errMsg[2048]; #define IsRegOnlySpeak(chptr) (chptr->mode.extmode & EXTCMODE_REGONLYSPEAK) -DLLFUNC int regonlyspeak_can_send (aClient* cptr, aChannel *chptr, char* message, Membership* lp, int notice); -DLLFUNC char * regonlyspeak_part_message (aClient* sptr, aChannel *chptr, char* comment); +int regonlyspeak_can_send (aClient* cptr, aChannel *chptr, char* message, Membership* lp, int notice); +char * regonlyspeak_part_message (aClient* sptr, aChannel *chptr, char* comment); MOD_TEST(regonlyspeak) { @@ -70,7 +70,7 @@ MOD_UNLOAD(regonlyspeak) return MOD_SUCCESS; } -DLLFUNC char *regonlyspeak_part_message (aClient *sptr, aChannel *chptr, char *comment) +char *regonlyspeak_part_message (aClient *sptr, aChannel *chptr, char *comment) { if (!comment) return NULL; @@ -81,7 +81,7 @@ DLLFUNC char *regonlyspeak_part_message (aClient *sptr, aChannel *chptr, char *c return comment; } -DLLFUNC int regonlyspeak_can_send (aClient *cptr, aChannel *chptr, char *message, Membership *lp, int notice) +int regonlyspeak_can_send (aClient *cptr, aChannel *chptr, char *message, Membership *lp, int notice) { Hook *h; int i; diff --git a/src/modules/chanmodes/stripcolor.c b/src/modules/chanmodes/stripcolor.c index 25e401868..a4e7f698d 100644 --- a/src/modules/chanmodes/stripcolor.c +++ b/src/modules/chanmodes/stripcolor.c @@ -34,9 +34,9 @@ Cmode_t EXTCMODE_STRIPCOLOR; #define IsStripColor(chptr) (chptr->mode.extmode & EXTCMODE_STRIPCOLOR) -DLLFUNC char *stripcolor_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice); -DLLFUNC char *stripcolor_prelocalpart(aClient *sptr, aChannel *chptr, char *comment); -DLLFUNC char *stripcolor_prelocalquit(aClient *sptr, char *comment); +char *stripcolor_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice); +char *stripcolor_prelocalpart(aClient *sptr, aChannel *chptr, char *comment); +char *stripcolor_prelocalquit(aClient *sptr, char *comment); MOD_TEST(stripcolor) { @@ -72,7 +72,7 @@ MOD_UNLOAD(stripcolor) return MOD_SUCCESS; } -DLLFUNC char *stripcolor_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice) +char *stripcolor_prechanmsg(aClient *sptr, aChannel *chptr, char *text, int notice) { Hook *h; int i; @@ -94,7 +94,7 @@ DLLFUNC char *stripcolor_prechanmsg(aClient *sptr, aChannel *chptr, char *text, return text; } -DLLFUNC char *stripcolor_prelocalpart(aClient *sptr, aChannel *chptr, char *comment) +char *stripcolor_prelocalpart(aClient *sptr, aChannel *chptr, char *comment) { if (!comment) return NULL; @@ -117,7 +117,7 @@ static int IsAnyChannelStripColor(aClient *sptr) } -DLLFUNC char *stripcolor_prelocalquit(aClient *sptr, char *comment) +char *stripcolor_prelocalquit(aClient *sptr, char *comment) { if (!comment) return NULL; diff --git a/src/modules/cloak.c b/src/modules/cloak.c index a60d0767a..edf2a880c 100644 --- a/src/modules/cloak.c +++ b/src/modules/cloak.c @@ -35,11 +35,11 @@ int CLOAK_IP_ONLY = 0; #define KEY2 cloak_key2 #define KEY3 cloak_key3 -DLLFUNC char *hidehost(aClient *acptr, char *host); -DLLFUNC char *cloakcsum(); -DLLFUNC int cloak_config_test(ConfigFile *, ConfigEntry *, int, int *); -DLLFUNC int cloak_config_run(ConfigFile *, ConfigEntry *, int); -DLLFUNC int cloak_config_posttest(int *); +char *hidehost(aClient *acptr, char *host); +char *cloakcsum(); +int cloak_config_test(ConfigFile *, ConfigEntry *, int, int *); +int cloak_config_run(ConfigFile *, ConfigEntry *, int); +int cloak_config_posttest(int *); static char *hidehost_ipv4(char *host); static char *hidehost_ipv6(char *host); @@ -117,7 +117,7 @@ char *p; } -DLLFUNC int cloak_config_test(ConfigFile *cf, ConfigEntry *ce, int type, int *errs) +int cloak_config_test(ConfigFile *cf, ConfigEntry *ce, int type, int *errs) { ConfigEntry *cep; int keycnt = 0, errors = 0; @@ -191,7 +191,7 @@ DLLFUNC int cloak_config_test(ConfigFile *cf, ConfigEntry *ce, int type, int *er return errors ? -1 : 1; } -DLLFUNC int cloak_config_posttest(int *errs) +int cloak_config_posttest(int *errs) { int errors = 0; @@ -205,7 +205,7 @@ int errors = 0; return errors ? -1 : 1; } -DLLFUNC int cloak_config_run(ConfigFile *cf, ConfigEntry *ce, int type) +int cloak_config_run(ConfigFile *cf, ConfigEntry *ce, int type) { ConfigEntry *cep; char buf[512], result[16]; @@ -257,7 +257,7 @@ char buf[512], result[16]; return 1; } -DLLFUNC char *hidehost(aClient *acptr, char *host) +char *hidehost(aClient *acptr, char *host) { char *p; @@ -279,7 +279,7 @@ DLLFUNC char *hidehost(aClient *acptr, char *host) return hidehost_normalhost(host); } -DLLFUNC char *cloakcsum() +char *cloakcsum() { return cloak_checksum; } diff --git a/src/modules/m_away.c b/src/modules/m_away.c index 8c361fd22..e4d65f651 100644 --- a/src/modules/m_away.c +++ b/src/modules/m_away.c @@ -28,7 +28,7 @@ CMD_FUNC(m_away); #define MSG_AWAY "AWAY" -DLLFUNC ModuleHeader MOD_HEADER(m_away) +ModuleHeader MOD_HEADER(m_away) = { "m_away", "4.2", diff --git a/src/modules/m_join.c b/src/modules/m_join.c index 7f945e07f..72d9b0d6a 100644 --- a/src/modules/m_join.c +++ b/src/modules/m_join.c @@ -24,9 +24,9 @@ /* Forward declarations */ CMD_FUNC(m_join); -DLLFUNC void _join_channel(aChannel *chptr, aClient *cptr, aClient *sptr, int flags); +void _join_channel(aChannel *chptr, aClient *cptr, aClient *sptr, int flags); CMD_FUNC(_do_join); -DLLFUNC int _can_join(aClient *cptr, aClient *sptr, aChannel *chptr, char *key, char *parv[]); +int _can_join(aClient *cptr, aClient *sptr, aChannel *chptr, char *key, char *parv[]); void _userhost_save_current(aClient *sptr); void _userhost_changed(aClient *sptr); void _send_join_to_local_users(aClient *sptr, aChannel *chptr); @@ -87,7 +87,7 @@ MOD_UNLOAD(m_join) * (eg: bans at the end), so don't change it unless you have a good reason * to do so -- Syzop. */ -DLLFUNC int _can_join(aClient *cptr, aClient *sptr, aChannel *chptr, char *key, char *parv[]) +int _can_join(aClient *cptr, aClient *sptr, aChannel *chptr, char *key, char *parv[]) { Link *lp; Ban *banned; @@ -220,7 +220,7 @@ void _send_join_to_local_users(aClient *sptr, aChannel *chptr) /* Routine that actually makes a user join the channel * this does no actual checking (banned, etc.) it just adds the user */ -DLLFUNC void _join_channel(aChannel *chptr, aClient *cptr, aClient *sptr, int flags) +void _join_channel(aChannel *chptr, aClient *cptr, aClient *sptr, int flags) { Hook *h; int i = 0; diff --git a/src/modules/m_mode.c b/src/modules/m_mode.c index deaa35971..5d601a573 100644 --- a/src/modules/m_mode.c +++ b/src/modules/m_mode.c @@ -25,8 +25,8 @@ /* Forward declarations */ CMD_FUNC(m_mode); CMD_FUNC(m_mlock); -DLLFUNC void _do_mode(aChannel *chptr, aClient *cptr, aClient *sptr, int parc, char *parv[], time_t sendts, int samode); -DLLFUNC void _set_mode(aChannel *chptr, aClient *cptr, int parc, char *parv[], u_int *pcount, +void _do_mode(aChannel *chptr, aClient *cptr, aClient *sptr, int parc, char *parv[], time_t sendts, int samode); +void _set_mode(aChannel *chptr, aClient *cptr, int parc, char *parv[], u_int *pcount, char pvar[MAXMODEPARAMS][MODEBUFLEN + 3], int bounce); CMD_FUNC(_m_umode); @@ -406,7 +406,7 @@ static void bounce_mode(aChannel *chptr, aClient *cptr, int parc, char *parv[]) * User or server is authorized to do the mode. This takes care of * setting the mode and relaying it to other users and servers. */ -DLLFUNC void _do_mode(aChannel *chptr, aClient *cptr, aClient *sptr, int parc, char *parv[], time_t sendts, int samode) +void _do_mode(aChannel *chptr, aClient *cptr, aClient *sptr, int parc, char *parv[], time_t sendts, int samode) { char pvar[MAXMODEPARAMS][MODEBUFLEN + 3]; int pcount; @@ -1365,7 +1365,7 @@ int paracount_for_chanmode_from_server(aClient *acptr, u_int what, char mode) /* set_mode * written by binary */ -DLLFUNC void _set_mode(aChannel *chptr, aClient *cptr, int parc, char *parv[], u_int *pcount, +void _set_mode(aChannel *chptr, aClient *cptr, int parc, char *parv[], u_int *pcount, char pvar[MAXMODEPARAMS][MODEBUFLEN + 3], int bounce) { char *curchr; diff --git a/src/modules/m_nick.c b/src/modules/m_nick.c index 15b47a344..3a75f8d38 100644 --- a/src/modules/m_nick.c +++ b/src/modules/m_nick.c @@ -36,7 +36,7 @@ ModuleHeader MOD_HEADER(m_nick) /* Forward declarations */ CMD_FUNC(m_nick); CMD_FUNC(m_uid); -DLLFUNC int _register_user(aClient *cptr, aClient *sptr, char *nick, char *username, char *umode, char *virthost, char *ip); +int _register_user(aClient *cptr, aClient *sptr, char *nick, char *username, char *umode, char *virthost, char *ip); int AllowClient(aClient *cptr, struct hostent *hp, char *sockhost, char *username); int check_client(aClient *cptr, char *username); diff --git a/src/modules/m_nopost.c b/src/modules/m_nopost.c index 9a3fc6cad..1cf018a69 100644 --- a/src/modules/m_nopost.c +++ b/src/modules/m_nopost.c @@ -47,8 +47,8 @@ struct { static void free_config(void); static void init_config(void); -DLLFUNC int m_nopost_config_test(ConfigFile *, ConfigEntry *, int, int *); -DLLFUNC int m_nopost_config_run(ConfigFile *, ConfigEntry *, int); +int m_nopost_config_test(ConfigFile *, ConfigEntry *, int, int *); +int m_nopost_config_run(ConfigFile *, ConfigEntry *, int); static int is_except_host(aClient *sptr); MOD_TEST(m_nopost) @@ -103,7 +103,7 @@ DynList *d, *d_next; memset(&cfg, 0, sizeof(cfg)); /* needed! */ } -DLLFUNC int m_nopost_config_test(ConfigFile *cf, ConfigEntry *ce, int type, int *errs) +int m_nopost_config_test(ConfigFile *cf, ConfigEntry *ce, int type, int *errs) { int errors = 0; ConfigEntry *cep; @@ -157,7 +157,7 @@ ConfigEntry *cep; return errors ? -1 : 1; } -DLLFUNC int m_nopost_config_run(ConfigFile *cf, ConfigEntry *ce, int type) +int m_nopost_config_run(ConfigFile *cf, ConfigEntry *ce, int type) { ConfigEntry *cep, *cep2; DynList *d; diff --git a/src/modules/m_pass.c b/src/modules/m_pass.c index 5498a855b..954b589be 100644 --- a/src/modules/m_pass.c +++ b/src/modules/m_pass.c @@ -37,7 +37,7 @@ ModuleHeader MOD_HEADER(m_pass) }; /* Forward declarations */ -DLLFUNC int _check_banned(aClient *cptr); +int _check_banned(aClient *cptr); MOD_TEST(m_pass) { @@ -67,7 +67,7 @@ MOD_UNLOAD(m_pass) } /** Handles zlines/gzlines/throttling/unknown connections */ -DLLFUNC int _check_banned(aClient *cptr) +int _check_banned(aClient *cptr) { aTKline *tk; aClient *acptr; diff --git a/src/modules/m_tkl.c b/src/modules/m_tkl.c index 87407c31c..3a8394868 100644 --- a/src/modules/m_tkl.c +++ b/src/modules/m_tkl.c @@ -48,7 +48,7 @@ CMD_FUNC(m_gzline); CMD_FUNC(m_tkline); CMD_FUNC(m_tzline); CMD_FUNC(m_spamfilter); -DLLFUNC int m_tkl_line(aClient *cptr, aClient *sptr, int parc, char *parv[], char* type); +int m_tkl_line(aClient *cptr, aClient *sptr, int parc, char *parv[], char* type); int _tkl_hash(unsigned int c); char _tkl_typetochar(int type); @@ -468,7 +468,7 @@ int ban_too_broad(char *usermask, char *hostmask) ** parv[3] = reason */ -DLLFUNC int m_tkl_line(aClient *cptr, aClient *sptr, int parc, char *parv[], char* type) +int m_tkl_line(aClient *cptr, aClient *sptr, int parc, char *parv[], char* type) { TS secs; int whattodo = 0; /* 0 = add 1 = del */ diff --git a/src/modules/m_user.c b/src/modules/m_user.c index d0a3d4837..565078402 100644 --- a/src/modules/m_user.c +++ b/src/modules/m_user.c @@ -22,7 +22,7 @@ #include "unrealircd.h" -DLLFUNC CMD_FUNC(m_user); +CMD_FUNC(m_user); #define MSG_USER "USER" @@ -62,7 +62,7 @@ MOD_UNLOAD(m_user) ** NOTE: Be advised that multiple USER messages are possible, ** hence, always check if a certain struct is already allocated... -- Syzop */ -DLLFUNC CMD_FUNC(m_user) +CMD_FUNC(m_user) { #define UFLAGS (UMODE_INVISIBLE|UMODE_WALLOP|UMODE_SERVNOTICE) char *username, *host, *server, *realname, *umodex = NULL, *virthost = diff --git a/src/modules/usermodes/censor.c b/src/modules/usermodes/censor.c index 1f7c1d83a..3a62d5b6f 100644 --- a/src/modules/usermodes/censor.c +++ b/src/modules/usermodes/censor.c @@ -22,8 +22,8 @@ long UMODE_CENSOR = 0L; char *censor_pre_usermsg(aClient *sptr, aClient *target, char *text, int notice); -DLLFUNC int censor_config_test(ConfigFile *, ConfigEntry *, int, int *); -DLLFUNC int censor_config_run(ConfigFile *, ConfigEntry *, int); +int censor_config_test(ConfigFile *, ConfigEntry *, int, int *); +int censor_config_run(ConfigFile *, ConfigEntry *, int); ModuleInfo *ModInfo = NULL; @@ -75,7 +75,7 @@ ConfigItem_badword *badword, *next; return MOD_SUCCESS; } -DLLFUNC int censor_config_test(ConfigFile *cf, ConfigEntry *ce, int type, int *errs) +int censor_config_test(ConfigFile *cf, ConfigEntry *ce, int type, int *errs) { int errors = 0; ConfigEntry *cep; @@ -185,7 +185,7 @@ DLLFUNC int censor_config_test(ConfigFile *cf, ConfigEntry *ce, int type, int *e } -DLLFUNC int censor_config_run(ConfigFile *cf, ConfigEntry *ce, int type) +int censor_config_run(ConfigFile *cf, ConfigEntry *ce, int type) { ConfigEntry *cep, *word = NULL; ConfigItem_badword *ca; diff --git a/src/modules/usermodes/noctcp.c b/src/modules/usermodes/noctcp.c index 075c93541..d4843535d 100644 --- a/src/modules/usermodes/noctcp.c +++ b/src/modules/usermodes/noctcp.c @@ -34,7 +34,7 @@ long UMODE_NOCTCP = 0L; #define IsNoCTCP(cptr) (cptr->umodes & UMODE_NOCTCP) -DLLFUNC char *noctcp_preusermsg(aClient *sptr, aClient *acptr, char *text, int notice); +char *noctcp_preusermsg(aClient *sptr, aClient *acptr, char *text, int notice); MOD_TEST(noctcp) { @@ -74,7 +74,7 @@ static int IsACTCP(char *s) return 0; } -DLLFUNC char *noctcp_preusermsg(aClient *sptr, aClient *acptr, char *text, int notice) +char *noctcp_preusermsg(aClient *sptr, aClient *acptr, char *text, int notice) { if (MyClient(sptr) && !notice && IsNoCTCP(acptr) && !IsOper(sptr) && IsACTCP(text)) {