diff --git a/filter/ngx_http_zstd_filter_module.c b/filter/ngx_http_zstd_filter_module.c index 6549382..d5784ba 100644 --- a/filter/ngx_http_zstd_filter_module.c +++ b/filter/ngx_http_zstd_filter_module.c @@ -641,7 +641,7 @@ ngx_http_zstd_accept_encoding(ngx_str_t *ae) { u_char *p; - p = ngx_strcasestrn(ae->data, "zstd", sizeof("zstd") - 1); + p = ngx_strcasestrn(ae->data, "zstd", sizeof("zstd") - 2); if (p == NULL) { return NGX_DECLINED; } @@ -1014,4 +1014,4 @@ ngx_conf_zstd_set_num_slot_with_negatives(ngx_conf_t *cf, ngx_command_t *cmd, vo } return NGX_CONF_OK; -} \ No newline at end of file +}