Commit aceca996 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

HTTP: zlib only supports deflate and gzip

Don't try to handle other codings with it. As of today, IANA lists
compress, exi and pack200-gzip as other legal values.
parent 5ca001c0
...@@ -1477,12 +1477,14 @@ static int Request( access_t *p_access, int64_t i_tell ) ...@@ -1477,12 +1477,14 @@ static int Request( access_t *p_access, int64_t i_tell )
else if( !strcasecmp( psz, "Content-Encoding" ) ) else if( !strcasecmp( psz, "Content-Encoding" ) )
{ {
msg_Dbg( p_access, "Content-Encoding: %s", p ); msg_Dbg( p_access, "Content-Encoding: %s", p );
if( strcasecmp( p, "identity" ) ) if( !strcasecmp( p, "identity" ) )
;
#ifdef HAVE_ZLIB_H #ifdef HAVE_ZLIB_H
else if( !strcasecmp( p, "gzip" ) || !strcasecmp( p, "deflate" ) )
p_sys->b_compressed = true; p_sys->b_compressed = true;
#else
msg_Warn( p_access, "Compressed content not supported. Rebuild with zlib support." );
#endif #endif
else
msg_Warn( p_access, "Unknown content coding: %s", p );
} }
else if( !strcasecmp( psz, "Pragma" ) ) else if( !strcasecmp( psz, "Pragma" ) )
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment