#define false 0
#endif
-#define ArrayLength(x) (sizeof(x)/sizeof(x[0]))
+#define ArrayLength(x) (sizeof(x)/sizeof(x[0]))
#define safestrncpy(dest, src, len) do { char *d = (dest); const char *s = (src); size_t l = strlen(s)+1; if ((len) < l) l = (len); memmove(d, s, l); d[l-1] = 0; } while (0)
#ifdef __GNUC__
# define verify(ptr) (void)(ptr)
#endif
-extern time_t now;
+extern unsigned long now;
extern int quit_services;
extern struct log_type *MAIN_LOG;
+extern const char git_version[];
typedef union irc_in_addr {
uint32_t in6_32[4];
#define match_ircglobs !mmatch
int mmatch(const char *glob, const char *newglob);
int match_ircglob(const char *text, const char *glob);
-int user_matches_glob(struct userNode *user, const char *glob, int include_nick);
+#define MATCH_USENICK 1
+#define MATCH_VISIBLE 2
+int user_matches_glob(struct userNode *user, const char *glob, int flags);
int is_ircmask(const char *text);
int is_gline(const char *text);
unsigned int n, found;\
verify(list->list);\
for (found=n=0; n<list->used; n++) {\
- if (list->list[n] == new_item) {\
- memmove(list->list+n, list->list+n+1, (list->used-n-1)*sizeof(list->list[n]));\
- found = 1;\
- list->used--;\
- }\
+ if (list->list[n] == new_item) {\
+ memmove(list->list+n, list->list+n+1, (list->used-n-1)*sizeof(list->list[n]));\
+ found = 1;\
+ list->used--;\
+ }\
}\
return found;\
}\
* minutes, and 10 seconds" (27 characters). Other languages will
* vary, so there's plenty of leeway.
*/
-#define INTERVALLEN 50
+#define INTERVALLEN 50
struct handle_info;
-char *intervalString(char *output, time_t interval, struct handle_info *hi);
+char *intervalString(char *output, unsigned long interval, struct handle_info *hi);
int getipbyname(const char *name, unsigned long *ip);
int set_policer_param(const char *param, void *data, void *extra);
const char *strtab(unsigned int ii);