[svn-commits] dvossel: branch 1.4 r233609 - /branches/1.4/main/utils.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Mon Dec 7 17:25:03 CST 2009


Author: dvossel
Date: Mon Dec  7 17:24:59 2009
New Revision: 233609

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=233609
Log:
hex escape control and non 7-bit clean characters in uri_encode

In ast_uri_encode, non 7-bit clean characters were being hex escaped
correctly, but control characters were not. 

(issue #16299)


Modified:
    branches/1.4/main/utils.c

Modified: branches/1.4/main/utils.c
URL: http://svnview.digium.com/svn/asterisk/branches/1.4/main/utils.c?view=diff&rev=233609&r1=233608&r2=233609
==============================================================================
--- branches/1.4/main/utils.c (original)
+++ branches/1.4/main/utils.c Mon Dec  7 17:24:59 2009
@@ -394,7 +394,7 @@
 
 	/* If there's no characters to convert, just go through and don't do anything */
 	while (*ptr) {
-		if (((unsigned char) *ptr) > 127 || (doreserved && strchr(reserved, *ptr)) ) {
+		if ((*ptr < 32) || (doreserved && strchr(reserved, *ptr))) {
 			/* Oops, we need to start working here */
 			if (!buf) {
 				buf = outbuf;




More information about the svn-commits mailing list