[BUG] ngx_http_sub_module fails to process single-char patterns
Yichun Zhang (agentzh)
agentzh at gmail.com
Wed Sep 3 19:06:52 UTC 2014
Hello!
I've noted a bug in nginx 1.7.4's standard ngx_http_sub_module that
single-char patterns are never handled properly but longer patterns
work. Consider the following minimal example:
location = /t {
default_type text/html;
return 200 "hello world";
sub_filter 'h' '';
}
Accessing /t gives the response body
hello world
instead of the expected output
ello world
The 'h' pattern is essentially ignored. Using longer patterns like
'he' in the example above works as expected though.
Best regards,
-agentzh
More information about the nginx-devel
mailing list