You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by Randy Terbush <ra...@hyperreal.org> on 1997/09/01 05:07:32 UTC

cvs commit: apachen/src/modules/proxy mod_proxy.c proxy_connect.c proxy_http.c proxy_util.c

randy       97/08/31 20:07:30

  Modified:    src/modules/proxy mod_proxy.c proxy_connect.c proxy_http.c
                        proxy_util.c
  Log:
  Convert log_*() to aplog_error().
  Something needs to be done with proxy_log_uerror() in here. I see no obvious
  reason not to replace it with aplog_error() but would like some feedback first.
  
  Revision  Changes    Path
  1.23      +9 -9      apachen/src/modules/proxy/mod_proxy.c
  
  Index: mod_proxy.c
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/modules/proxy/mod_proxy.c,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -r1.22 -r1.23
  --- mod_proxy.c	1997/08/18 13:12:06	1.22
  +++ mod_proxy.c	1997/09/01 03:07:26	1.23
  @@ -221,9 +221,8 @@
       /* Split request into user, password, host, port */
       err = proxy_canon_netloc(r->pool, &url_copy, &user, &password, &host, &port);
   
  -    if (err != NULL)
  -    {
  -	log_error(err, r->server);
  +    if (err != NULL) {
  +	aplog_error(APLOG_MARK, APLOG_ERR, r->server, err);
   	return DECLINED;
       }
   
  @@ -251,8 +250,10 @@
   		       NULL);
   
   	table_set(r->headers_out, "Location", nuri);
  -	log_error(pstrcat(r->pool, "Domain missing: ", r->uri, " sent to ", nuri,
  -		      ref ? " from " : NULL, ref, NULL), r->server);
  +	aplog_error(APLOG_MARK, APLOG_ERR, r->server,
  +		    pstrcat(r->pool, "Domain missing: ", r->uri, " sent to ", nuri,
  +			    ref ? " from " : NULL, ref, NULL));
  +
   	return REDIRECT;
       }
   }
  @@ -307,15 +308,14 @@
   	for (direct_connect=ii=0; ii < conf->dirconn->nelts && !direct_connect; ii++)
   	{
   	    direct_connect = list[ii].matcher (&list[ii], r);
  -	    /*log_error("URI and NoProxy:", r->server);*/
  -	    /*log_error(r->uri, r->server);*/
  -	    /*log_error(list[ii].name, r->server);*/
  +	    aplog_error(APLOG_MARK, APLOG_DEBUG, r->server,
  +			"URI and NoProxy: %s: %s", r->uri, list[ii].name);
   	}
   #if DEBUGGING
   	{
   	    char msg[256];
   	    sprintf (msg, (direct_connect)?"NoProxy for %s":"UseProxy for %s", r->uri);
  -	    log_error(msg, r->server);
  +	    aplog_error(APLOG_MARK, APLOG_DEBUG, r->server, msg);
   	}
   #endif
       }
  
  
  
  1.14      +2 -1      apachen/src/modules/proxy/proxy_connect.c
  
  Index: proxy_connect.c
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/modules/proxy/proxy_connect.c,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -r1.13 -r1.14
  --- proxy_connect.c	1997/08/17 13:56:27	1.13
  +++ proxy_connect.c	1997/09/01 03:07:27	1.14
  @@ -150,7 +150,8 @@
       sock = psocket(r->pool, PF_INET, SOCK_STREAM, IPPROTO_TCP);  
       if (sock == -1)
       {     
  -        log_error("proxy: error creating socket", r->server);
  +        aplog_error(APLOG_MARK, APLOG_ERR, r->server,
  +		    "proxy: error creating socket");
           return SERVER_ERROR;
       }     
    
  
  
  
  1.30      +2 -1      apachen/src/modules/proxy/proxy_http.c
  
  Index: proxy_http.c
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/modules/proxy/proxy_http.c,v
  retrieving revision 1.29
  retrieving revision 1.30
  diff -u -r1.29 -r1.30
  --- proxy_http.c	1997/08/23 22:59:11	1.29
  +++ proxy_http.c	1997/09/01 03:07:27	1.30
  @@ -223,7 +223,8 @@
       sock = psocket(pool, PF_INET, SOCK_STREAM, IPPROTO_TCP);
       if (sock == -1)
       {
  -	log_error("proxy: error creating socket", r->server);
  +	aplog_error(APLOG_MARK, APLOG_ERR, r->server,
  +		    "proxy: error creating socket");
   	return SERVER_ERROR;
       }
       
  
  
  
  1.25      +1 -1      apachen/src/modules/proxy/proxy_util.c
  
  Index: proxy_util.c
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/modules/proxy/proxy_util.c,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -r1.24 -r1.25
  --- proxy_util.c	1997/08/23 22:59:11	1.24
  +++ proxy_util.c	1997/09/01 03:07:28	1.25
  @@ -831,7 +831,7 @@
       err = proxy_canon_netloc(r->pool, &url, &user, &password, &host, &port);
   
       if (err != NULL)
  -	log_error(err, r->server);
  +	aplog_error(APLOG_MARK, APLOG_ERR, r->server, err);
   
       r->hostname = host;