Commit f3f29013 authored by Garrett Rooney's avatar Garrett Rooney
Browse files

Fix compile time warnings.

Pointed out by: jorton

* modules/proxy/mod_proxy_fcgi.c
  Add include of util_script.h to pick up some function prototypes.
  (send_begin_request): Initialize the reserved bytes in the request
   body to zero.
  (dispatch): Use APR_SIZE_T_FMT instead of %d when logging an apr_size_t.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@397968 13f79535-47bb-0310-9956-ffa450edef68
parent 8a4c1628
Loading
Loading
Loading
Loading
+7 −1
Changes for modules/proxy/mod_proxy_fcgi.c: 7 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -16,6 +16,7 @@

#include "mod_proxy.h"
#include "fcgi_protocol.h"
#include "util_script.h"

module AP_MODULE_DECLARE_DATA proxy_fcgi_module;

@@ -240,6 +241,11 @@ static apr_status_t send_begin_request(proxy_conn_rec *conn, int request_id)
    brb.roleB1 = ((FCGI_RESPONDER >> 8) & 0xff);
    brb.roleB0 = ((FCGI_RESPONDER) & 0xff); 
    brb.flags = FCGI_KEEP_CONN;
    brb.reserved[0] = 0;
    brb.reserved[1] = 0;
    brb.reserved[2] = 0;
    brb.reserved[3] = 0;
    brb.reserved[4] = 0;

    fcgi_header_to_array(&header, farray);
    fcgi_begin_request_body_to_array(&brb, abrb);
@@ -673,7 +679,7 @@ static apr_status_t dispatch(proxy_conn_rec *conn, request_rec *r,
            if (readbuflen != FCGI_HEADER_LEN) {
                ap_log_error(APLOG_MARK, APLOG_ERR, 0, r->server,
                             "proxy: FCGI: Failed to read entire header "
                             "got %d wanted %d", 
                             "got %" APR_SIZE_T_FMT " wanted %d", 
                             readbuflen, FCGI_HEADER_LEN);
                rv = APR_EINVAL;
                break;