ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/svn/ircd-hybrid/trunk/src/hostmask.c
(Generate patch)

Comparing ircd-hybrid-7.2/src/hostmask.c (file contents):
Revision 34 by lusky, Sun Oct 2 21:05:51 2005 UTC vs.
Revision 1011 by michael, Fri Sep 18 10:14:09 2009 UTC

# Line 25 | Line 25
25   #include "stdinc.h"
26   #include "memory.h"
27   #include "ircd_defs.h"
28 < #include "tools.h"
28 > #include "list.h"
29   #include "s_conf.h"
30   #include "hostmask.h"
31   #include "numeric.h"
# Line 325 | Line 325 | mask_addr(struct irc_ssaddr *ip, int bit
325  
326      mask = ~((1 << (8 - m)) -1 );
327      v6_base_ip->sin6_addr.s6_addr[n] = v6_base_ip->sin6_addr.s6_addr[n] & mask;
328 <    for (i = n + 1; n < 16; i++)
329 <      v6_base_ip->sin6_addr.s6_addr[n] = 0;
328 >    for (i = n + 1; i < 16; i++)
329 >      v6_base_ip->sin6_addr.s6_addr[i] = 0;
330    }
331   #endif
332   }
# Line 419 | Line 419 | get_mask_hash(const char *text)
419    const char *hp = "", *p;
420  
421    for (p = text + strlen(text) - 1; p >= text; p--)
422 <    if (*p == '*' || *p == '?')
422 >    if (IsMWildChar(*p))
423        return hash_text(hp);
424      else if (*p == '.')
425        hp = p + 1;

Diff Legend

Removed lines
+ Added lines
< Changed lines (old)
> Changed lines (new)