Committer : entrope
CVSROOT : /cvsroot/undernet-ircu
Module : ircu2.10
Commit time: 2005-09-12 16:12:08 UTC
Modified files:
ChangeLog RELEASE.NOTES ircd/ircd_string.c ircd/m_join.c
Log message:
Fix previous commit and parsing of ipmasks like 127/8.
---------------------- diff included ----------------------
Index: ircu2.10/ChangeLog
diff -u ircu2.10/ChangeLog:1.692 ircu2.10/ChangeLog:1.693
--- ircu2.10/ChangeLog:1.692 Mon Sep 12 08:47:30 2005
+++ ircu2.10/ChangeLog Mon Sep 12 09:11:58 2005
@@ -1,5 +1,11 @@
2005-09-12 Michael Poole <[EMAIL PROTECTED]>
+ * RELEASE.NOTES: Note the resolution of ambiguous ipmasks.
+
+ * ircd/ircd_string.c (ipmask_parse): Implement it.
+
+2005-09-12 Michael Poole <[EMAIL PROTECTED]>
+
* ircd/m_join.c (m_join): If we find an empty key, null out the
key pointer.
Index: ircu2.10/RELEASE.NOTES
diff -u ircu2.10/RELEASE.NOTES:1.21 ircu2.10/RELEASE.NOTES:1.22
--- ircu2.10/RELEASE.NOTES:1.21 Sun Sep 11 20:40:16 2005
+++ ircu2.10/RELEASE.NOTES Mon Sep 12 09:11:58 2005
@@ -87,7 +87,8 @@
IP masks (as used in bans, G-lines, etc) are now parsed in a more
forgiving manner. 127.0.0.0/8, 127.* and 127/8 are all accepted and
-mean the same thing.
+mean the same thing. Ambiguous expressions like 127/8 are interpreted
+as IPv4 masks; to interpret it as an IPv6 mask, use 127:/8.
Configuration Changes:
Index: ircu2.10/ircd/ircd_string.c
diff -u ircu2.10/ircd/ircd_string.c:1.23 ircu2.10/ircd/ircd_string.c:1.24
--- ircu2.10/ircd/ircd_string.c:1.23 Sun Sep 11 20:40:17 2005
+++ ircu2.10/ircd/ircd_string.c Mon Sep 12 09:11:58 2005
@@ -18,7 +18,7 @@
*/
/** @file
* @brief Implementation of string operations.
- * @version $Id: ircd_string.c,v 1.23 2005/09/12 03:40:17 entrope Exp $
+ * @version $Id: ircd_string.c,v 1.24 2005/09/12 16:11:58 entrope Exp $
*/
#include "config.h"
@@ -628,7 +628,7 @@
ip->in6_16[colon + jj] = 0;
}
return pos;
- } else if (dot) {
+ } else if (dot || strchr(input, '/')) {
unsigned int addr;
int len = ircd_aton_ip4(input, &addr, pbits);
if (len) {
Index: ircu2.10/ircd/m_join.c
diff -u ircu2.10/ircd/m_join.c:1.31 ircu2.10/ircd/m_join.c:1.32
--- ircu2.10/ircd/m_join.c:1.31 Mon Sep 12 08:47:31 2005
+++ ircu2.10/ircd/m_join.c Mon Sep 12 09:11:58 2005
@@ -20,7 +20,7 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*
- * $Id: m_join.c,v 1.31 2005/09/12 15:47:31 entrope Exp $
+ * $Id: m_join.c,v 1.32 2005/09/12 16:11:58 entrope Exp $
*/
#include "config.h"
@@ -132,7 +132,7 @@
*keys++ = '\0';
/* Empty keys are the same as no keys. */
- if (!key[0])
+ if (key && !key[0])
key = 0;
clean_channelname(name);
----------------------- End of diff -----------------------
_______________________________________________
Patches mailing list
[email protected]
http://undernet.sbg.org/mailman/listinfo/patches