diff libpurple/protocols/jabber/jutil.c @ 30205:738741a7a692

jabber: Exclude ASCII 127 (Delete) from allowed SASLprep characters Tested with libidn, so changed it for the non-libidn code. Also, disable a test that cannot succeed without libidn (since it contains a vulgar 1/2).
author Paul Aurich <paul@darkrain42.org>
date Thu, 17 Jun 2010 21:21:30 +0000
parents e3eda7aa0653
children a8cc50c2279f
line wrap: on
line diff
--- a/libpurple/protocols/jabber/jutil.c	Thu Jun 17 19:17:32 2010 +0000
+++ b/libpurple/protocols/jabber/jutil.c	Thu Jun 17 21:21:30 2010 +0000
@@ -303,8 +303,10 @@
 
 	c = (const guchar *)in;
 	for ( ; *c; ++c) {
-		if (*c > 0x7f ||
+		if (*c > 0x7f || /* Non-ASCII characters */
+				*c == 0x7f || /* ASCII Delete character */
 				(*c < 0x20 && *c != '\t' && *c != '\n' && *c != '\r'))
+					/* ASCII control characters */
 			return NULL;
 	}