Remove 'type' argument of flood_prot()

All callers of flood_prot() were supplying { get_flood_types(flood_type), flood_type } as the second and third arguments,
except one that supplied { get_flood_types(CTCP_FLOOD), CTCP_ACTION_FLOOD }.

Hardwiring this logic in to flood_prot() lets us remove the 'type' argument without changing the behaviour.
This commit is contained in:
Kevin Easton
2017-01-18 00:11:49 +11:00
parent 7dce90d809
commit 78dbdea441
4 changed files with 21 additions and 22 deletions

View File

@@ -596,7 +596,7 @@ extern Function_ptr *global;
/* flood.c */
#define is_other_flood (*(int (*)(ChannelList *, NickList *, int, int *))global[IS_OTHER_FLOOD])
#define check_flooding (*(int (*)(char *, int , char *, char *))global[CHECK_FLOODING])
#define flood_prot (*(int (*)(char *, char *, char *, int , int , char *))global[FLOOD_PROT])
#define flood_prot (*(int (*)(char *, char *, int , int , char *))global[FLOOD_PROT])
/* expr.c */
#define next_unit (*(char *(*)(char *, const char *, int *, int ))global[NEXT_UNIT])