X-Git-Url: https://jfr.im/git/irc/rqf/shadowircd.git/blobdiff_plain/212380e3f42f585dc1ea927402252eb943f91f7b..7f4fa1956ee087c272dd260feb6d7e1ef34d641b:/include/irc_string.h diff --git a/include/irc_string.h b/include/irc_string.h index d2bd104..3dd8353 100644 --- a/include/irc_string.h +++ b/include/irc_string.h @@ -21,7 +21,7 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * USA * - * $Id: irc_string.h 678 2006-02-03 20:25:01Z jilles $ + * $Id: irc_string.h 3538 2007-07-26 14:21:57Z jilles $ */ #ifndef INCLUDED_irc_string_h @@ -34,11 +34,13 @@ * match - compare name with mask, mask may contain * and ? as wildcards * match - returns 1 on successful match, 0 otherwise * + * mask_match - compare one mask to another * match_esc - compare with support for escaping chars * match_cidr - compares u!h@addr with u!h@addr/cidr * match_ips - compares addr with addr/cidr in ascii form */ extern int match(const char *mask, const char *name); +extern int mask_match(const char *oldmask, const char *newmask); extern int match_esc(const char *mask, const char *name); extern int match_cidr(const char *mask, const char *name); extern int match_ips(const char *mask, const char *name); @@ -129,7 +131,7 @@ char *strip_tabs(char *dest, const unsigned char *src, size_t len); const char *myctime(time_t); -#define EmptyString(x) (!(x) || (*(x) == '\0')) +#define EmptyString(x) ((x) == NULL || *(x) == '\0') #define CheckEmpty(x) EmptyString(x) ? "" : x char *strtoken(char **save, char *str, const char *fs);