apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wr...@apache.org
Subject svn commit: r170464 - /apr/apr/trunk/network_io/unix/inet_pton.c
Date Mon, 16 May 2005 21:46:30 GMT
Author: wrowe
Date: Mon May 16 14:46:30 2005
New Revision: 170464

URL: http://svn.apache.org/viewcvs?rev=170464&view=rev
Log:

  Safe cast to bring pointer arithmetic in line with a much smaller
  result set.

Modified:
    apr/apr/trunk/network_io/unix/inet_pton.c

Modified: apr/apr/trunk/network_io/unix/inet_pton.c
URL: http://svn.apache.org/viewcvs/apr/apr/trunk/network_io/unix/inet_pton.c?rev=170464&r1=170463&r2=170464&view=diff
==============================================================================
--- apr/apr/trunk/network_io/unix/inet_pton.c (original)
+++ apr/apr/trunk/network_io/unix/inet_pton.c Mon May 16 14:46:30 2005
@@ -116,7 +116,7 @@
 	const char *pch;
 
 	if ((pch = strchr(digits, ch)) != NULL) {
-	    unsigned int new = *tp * 10 + (pch - digits);
+	    unsigned int new = *tp * 10 + (unsigned int)(pch - digits);
 
 	    if (new > 255)
 		return (0);



Mime
View raw message