Commit a35a6d64 authored by Justin Erenkrantz's avatar Justin Erenkrantz
Browse files

Style guide conformance fixes (remove tabs, enforce {}s, no long lines, etc).

This file has bugged me for ages.  Much better to do this now than later.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@91805 13f79535-47bb-0310-9956-ffa450edef68
parent d72fe48a
Loading
Loading
Loading
Loading
+146 −143
Original line number Diff line number Diff line
@@ -143,7 +143,7 @@ AP_DECLARE(int) ap_set_keepalive(request_rec *r)
                                                "Transfer-Encoding"),
                                  "chunked")
            || ((r->proto_num >= HTTP_VERSION(1,1))
		&& (r->chunked = 1))) /* THIS CODE IS CORRECT, see comment above. */
                && (r->chunked = 1))) /* THIS CODE IS CORRECT, see above. */
        && r->server->keep_alive
        && (r->server->keep_alive_timeout > 0)
        && ((r->server->keep_alive_max == 0)
@@ -552,8 +552,10 @@ apr_status_t ap_http_filter(ap_filter_t *f, apr_bucket_brigade *b,
        else if (lenp) {
            const char *pos = lenp;

            while (apr_isdigit(*pos) || apr_isspace(*pos))
            while (apr_isdigit(*pos) || apr_isspace(*pos)) {
                ++pos;
            }

            if (*pos == '\0') {
                ctx->state = BODY_LENGTH;
                ctx->remaining = atol(lenp);
@@ -708,8 +710,9 @@ AP_DECLARE(int) ap_index_of_response(int status)
    LEVEL_500, RESPONSE_CODES};
    int i, pos;

    if (status < 100)           /* Below 100 is illegal for HTTP status */
    if (status < 100) {               /* Below 100 is illegal for HTTP status */
        return LEVEL_500;
    }

    for (i = 0; i < 5; i++) {
        status -= 100;
@@ -1125,8 +1128,8 @@ AP_CORE_DECLARE_NONSTD(apr_status_t) ap_http_header_filter(ap_filter_t *f,
        apr_table_unset(r->headers_out, "Content-Length");
    }

    apr_table_setn(r->headers_out, "Content-Type", ap_make_content_type(r,
        r->content_type));
    apr_table_setn(r->headers_out, "Content-Type", 
                   ap_make_content_type(r, r->content_type));

    if (r->content_encoding) {
        apr_table_setn(r->headers_out, "Content-Encoding",
@@ -2285,7 +2288,8 @@ AP_CORE_DECLARE_NONSTD(apr_status_t) ap_byterange_filter(ap_filter_t *f,
        if (num_ranges == -1) {
            ap_remove_output_filter(f);
            bsend = apr_brigade_create(r->pool);
            e = ap_bucket_error_create(HTTP_RANGE_NOT_SATISFIABLE, NULL, r->pool);
            e = ap_bucket_error_create(HTTP_RANGE_NOT_SATISFIABLE, NULL, 
                                       r->pool);
            APR_BRIGADE_INSERT_TAIL(bsend, e);
            e = apr_bucket_eos_create();
            APR_BRIGADE_INSERT_TAIL(bsend, e);
@@ -2535,4 +2539,3 @@ static int ap_set_byterange(request_rec *r)

    return num_ranges;
}