fix segfault or parsing error in '<!--# if expr="$var = /" -->'

This commit is contained in:
Igor Sysoev 2007-05-02 08:07:37 +00:00
parent 9c710c0569
commit dbdeafe6a0

View File

@ -2376,7 +2376,7 @@ ngx_http_ssi_if(ngx_http_request_t *r, ngx_http_ssi_ctx_t *ctx,
p++;
}
if (p < last && *p == '/') {
if (p < last - 1 && *p == '/') {
if (*(last - 1) != '/') {
goto invalid_expression;
}