httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kot...@apache.org
Subject svn commit: r1771791 - /httpd/httpd/trunk/modules/filters/mod_brotli.c
Date Mon, 28 Nov 2016 18:40:24 GMT
Author: kotkov
Date: Mon Nov 28 18:40:23 2016
New Revision: 1771791

URL: http://svn.apache.org/viewvc?rev=1771791&view=rev
Log:
mod_brotli: Explicitly cast 'const uint8_t *' to 'const char *' when using
the data received from Brotli to create a bucket.

This fixes a /W4 warning in my environment, and should also allow building
mod_brotli on NetWare.

Submitted by: NormW <normw gknw.net>

Modified:
    httpd/httpd/trunk/modules/filters/mod_brotli.c

Modified: httpd/httpd/trunk/modules/filters/mod_brotli.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/filters/mod_brotli.c?rev=1771791&r1=1771790&r2=1771791&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/filters/mod_brotli.c (original)
+++ httpd/httpd/trunk/modules/filters/mod_brotli.c Mon Nov 28 18:40:23 2016
@@ -240,7 +240,7 @@ static apr_status_t process_chunk(brotli
             output = BrotliEncoderTakeOutput(ctx->state, &output_len);
             ctx->total_out += output_len;
 
-            b = apr_bucket_transient_create(output, output_len,
+            b = apr_bucket_transient_create((const char *)output, output_len,
                                             ctx->bb->bucket_alloc);
             APR_BRIGADE_INSERT_TAIL(ctx->bb, b);
 
@@ -289,7 +289,7 @@ static apr_status_t flush(brotli_ctx_t *
         output = BrotliEncoderTakeOutput(ctx->state, &output_len);
         ctx->total_out += output_len;
 
-        b = apr_bucket_heap_create(output, output_len, NULL,
+        b = apr_bucket_heap_create((const char *)output, output_len, NULL,
                                    ctx->bb->bucket_alloc);
         APR_BRIGADE_INSERT_TAIL(ctx->bb, b);
     }



Mime
View raw message