Files
bitchx/include/flood.h
Kevin Easton 3f87eb31b1 Standardise header include guards
Tokens that begin with two underscores __* or an underscore and an uppercase letter _X* are reserved,
so we should avoid those for our own include guards.  The standard I'm settling on for foo.h is FOO_H_.
2017-05-10 23:30:11 +10:00

37 lines
764 B
C

/*
* flood.h: header file for flood.c
*
* @(#)$Id$
*/
#ifndef FLOOD_H_
#define FLOOD_H_
enum flood_type {
MSG_FLOOD,
PUBLIC_FLOOD,
NOTICE_FLOOD,
WALL_FLOOD,
WALLOP_FLOOD,
CTCP_FLOOD,
INVITE_FLOOD,
CDCC_FLOOD,
CTCP_ACTION_FLOOD,
NICK_FLOOD,
DEOP_FLOOD,
KICK_FLOOD,
JOIN_FLOOD
};
#define FLOOD_FLAG(t) (1U << (t))
int BX_check_flooding(char *nick, enum flood_type type, char *line, char *channel);
int BX_is_other_flood(ChannelList *channel, NickList *nick, enum flood_type type, int *t_flood);
int BX_flood_prot(char *nick, char *userhost, enum flood_type flood_type, int ignoretime, char *channel);
void clean_flood_list(void);
#include "hash.h"
#define FLOOD_HASHSIZE 31
extern HashEntry no_flood_list[FLOOD_HASHSIZE];
#endif /* FLOOD_H_ */