[svn] - fix a possible problem with ipv6

This commit is contained in:
nenolod 2007-07-06 00:54:54 -07:00
parent 762cc38cf9
commit 514235a762
3 changed files with 18 additions and 3 deletions

View file

@ -1,3 +1,14 @@
nenolod 2007/07/06 07:48:28 UTC (20070706-3522)
Log:
- new ip cloaking module
Changes: Modified:
+1 -0 trunk/extensions/Makefile.in (File Modified)
+246 -33 trunk/extensions/ip_cloaking.c (File Modified)
+ - trunk/extensions/ip_cloaking_old.c (File Added)
jilles 2007/06/30 22:15:35 UTC (20070630-3520) jilles 2007/06/30 22:15:35 UTC (20070630-3520)
Log: Log:
monitor: send the same message buffer to all users monitor: send the same message buffer to all users

View file

@ -1,4 +1,4 @@
/* $Id: ip_cloaking.c 3522 2007-07-06 07:48:28Z nenolod $ */ /* $Id: ip_cloaking.c 3524 2007-07-06 07:54:54Z nenolod $ */
#include "stdinc.h" #include "stdinc.h"
#include "modules.h" #include "modules.h"
@ -42,7 +42,7 @@ mapi_hfn_list_av1 ip_cloaking_hfnlist[] = {
}; };
DECLARE_MODULE_AV1(ip_cloaking, _modinit, _moddeinit, NULL, NULL, DECLARE_MODULE_AV1(ip_cloaking, _modinit, _moddeinit, NULL, NULL,
ip_cloaking_hfnlist, "$Revision: 3522 $"); ip_cloaking_hfnlist, "$Revision: 3524 $");
static void static void
distribute_hostchange(struct Client *client) distribute_hostchange(struct Client *client)
@ -107,6 +107,10 @@ do_host_cloak_ip(const char *inbuf, char *outbuf)
strncpy(buf, inbuf, HOSTLEN); strncpy(buf, inbuf, HOSTLEN);
tptr = strrchr(buf, '.'); tptr = strrchr(buf, '.');
if (tptr == NULL)
return;
*tptr++ = '\0'; *tptr++ = '\0';
snprintf(outbuf, HOSTLEN, "%s.%x", buf, accum); snprintf(outbuf, HOSTLEN, "%s.%x", buf, accum);

View file

@ -1 +1 @@
#define SERNO "20070630-3520" #define SERNO "20070706-3522"