Skip to content

When "brotli" is disabled and "gzip" is enabled, responses are not compressed #270

@fleabitdev

Description

@fleabitdev

Version: 3.6.1

To reproduce: Enable the "gzip" feaure, disable the "brotli" feature, and serve a text/plain document using rouille::content_encoding::apply(). Access that document using a browser which accepts the encodings gzip and br.

Expected behaviour: The response should be gzip-compressed.

Observed behaviour: rouille::content_encoding::apply() prioritises brotli encoding over gzip encoding, even when the "brotli" feature is disabled. Under those circumstances, the brotli() function in that module is stubbed out, so the response is not compressed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions