On Oct 12, 2005, at 6:09 AM, Joe Orton wrote:

On Tue, Oct 11, 2005 at 09:43:35PM -0000, Jim Jagielski wrote:
...

Modified: httpd/httpd/branches/2.2.x/modules/proxy/proxy_util.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/branches/2.2.x/ modules/proxy/proxy_util.c?rev=312964&r1=312963&r2=312964&view=diff ===================================================================== =========
--- httpd/httpd/branches/2.2.x/modules/proxy/proxy_util.c (original)
+++ httpd/httpd/branches/2.2.x/modules/proxy/proxy_util.c Tue Oct 11 14:43:32 2005
@@ -1212,24 +1212,34 @@
                                                   const char *url)
 {
     proxy_worker *worker;
-    char *c, *uri = apr_pstrdup(p, url);
+    proxy_worker *max_worker = NULL;
+    int max_match = 0;
+    int url_length;
+    int worker_name_length;
+    char *c;
     int i;

-    c = strchr(uri, ':');
+    c = strchr(url, ':');
     if (c == NULL || c[1] != '/' || c[2] != '/' || c[3] == '\0')
        return NULL;


That broke the -Wall -Werror build with --enable-maintainer-mode

cc1: warnings being treated as errors
proxy_util.c: In function 'ap_proxy_get_worker':
proxy_util.c:1222: warning: passing argument 1 of 'ap_strchr' discards qualifiers from pointer target type

is this the code which is about to be removed anyway?


Argf. Yeah, that should be fixed. Of course, we should also, esp
in the the 2.3/4 trunk and the 2.3/4 branch standardize all our
usage of strchr. It's current a mix and mess of all flavors :)

I'll fix this later on today.

Reply via email to