Skip to content

Commit

Permalink
bugfix: fix zstd accept-encoding match bug (#20) (#21)
Browse files Browse the repository at this point in the history
  • Loading branch information
drawing authored Apr 6, 2023
1 parent 25d88c2 commit 4582ef9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions filter/ngx_http_zstd_filter_module.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;
}
Expand Down Expand Up @@ -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;
}
}

0 comments on commit 4582ef9

Please sign in to comment.