]> git.pld-linux.org Git - packages/lighttpd.git/commitdiff
- change compress.bzip2 to compress.allowed_encodings instead (like mod_deflate in...
authorElan Ruusamäe <glen@pld-linux.org>
Fri, 19 Sep 2008 11:30:29 +0000 (11:30 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    lighttpd-mod_compress-disable-bzip2.patch -> 1.2

lighttpd-mod_compress-disable-bzip2.patch

index 01775eaadccb2f21b5e932303d1dd178ae8950fa..93fe92f031c285ec6a139be28d85f65a839e1993 100644 (file)
@@ -1,5 +1,5 @@
---- lighttpd-1.4.19/src/mod_compress.c~        2008-09-19 13:00:02.000000000 +0300
-+++ lighttpd-1.4.19/src/mod_compress.c 2008-09-19 13:24:30.921429633 +0300
+--- lighttpd-1.4.19/src/mod_compress.c 2008-09-19 13:24:30.921429633 +0300
++++ lighttpd-1.4.19/src/mod_compress.c 2008-09-19 14:16:06.292324544 +0300
 @@ -46,6 +46,7 @@
  #endif
  
  #endif
  #ifdef USE_ZLIB
                                srv_encodings |= HTTP_ACCEPT_ENCODING_GZIP;
---- lighttpd-1.4.19/doc/compress.txt~  2006-10-04 16:26:23.000000000 +0300
-+++ lighttpd-1.4.19/doc/compress.txt   2008-09-19 13:27:27.571638906 +0300
-@@ -32,6 +32,9 @@
+@@ -689,7 +702,6 @@
+                       if (NULL != (ds = (data_string *)array_get_element(con->request.headers, "Accept-Encoding"))) {
+                               int accept_encoding = 0;
+                               char *value = ds->value->ptr;
+-                              int srv_encodings = 0;
+                               int matched_encodings = 0;
+                               /* get client side support encodings */
+@@ -697,25 +709,12 @@
+                               if (NULL != strstr(value, "deflate")) accept_encoding |= HTTP_ACCEPT_ENCODING_DEFLATE;
+                               if (NULL != strstr(value, "compress")) accept_encoding |= HTTP_ACCEPT_ENCODING_COMPRESS;
+ #ifdef USE_BZ2LIB
+-                              if (p->conf.bzip2) {
+-                                      if (NULL != strstr(value, "bzip2")) accept_encoding |= HTTP_ACCEPT_ENCODING_BZIP2;
+-                              }
++                              if (NULL != strstr(value, "bzip2")) accept_encoding |= HTTP_ACCEPT_ENCODING_BZIP2;
+ #endif
+                               if (NULL != strstr(value, "identity")) accept_encoding |= HTTP_ACCEPT_ENCODING_IDENTITY;
+-                              /* get server side supported ones */
+-#ifdef USE_BZ2LIB
+-                              if (p->conf.bzip2) {
+-                                      srv_encodings |= HTTP_ACCEPT_ENCODING_BZIP2;
+-                              }
+-#endif
+-#ifdef USE_ZLIB
+-                              srv_encodings |= HTTP_ACCEPT_ENCODING_GZIP;
+-                              srv_encodings |= HTTP_ACCEPT_ENCODING_DEFLATE;
+-#endif
+-
+                               /* find matching entries */
+-                              matched_encodings = accept_encoding & srv_encodings;
++                              matched_encodings = accept_encoding & p->conf.allowed_encodings;
+                               if (matched_encodings) {
+                                       const char *dflt_gzip = "gzip";
+--- lighttpd-1.4.19/doc/compress.txt   2008-09-19 13:27:27.571638906 +0300
++++ lighttpd-1.4.19/doc/compress.txt   2008-09-19 14:24:12.308407368 +0300
+@@ -32,6 +32,12 @@
  Options
  =======
  
-+compress.bzip2
-+  enable/disable bzip2 support.
++compress.allowed_encodings
++  override default set of allowed encodings
++
++  e.g.: ::
++    compress.allowed_encodings = ("bzip2", "gzip", "deflate")
 +
  compress.cache-dir
    name of the directory where compressed content will be cached
This page took 0.033427 seconds and 4 git commands to generate.