diff options
author | Ruslan Ermilov <ru@nginx.com> | 2011-11-23 10:22:44 +0000 |
---|---|---|
committer | Ruslan Ermilov <ru@nginx.com> | 2011-11-23 10:22:44 +0000 |
commit | 1e5f2391704c252fcd01f798a18aa8558376cb1a (patch) | |
tree | 604c50f4a4c2a44289317cd9c388982ab9676ee4 /src | |
parent | ca2cce23cc0df265a589c006ba4a9d7310df6104 (diff) | |
download | nginx-1e5f2391704c252fcd01f798a18aa8558376cb1a.tar.gz nginx-1e5f2391704c252fcd01f798a18aa8558376cb1a.zip |
Fixed "rotate" to always work when combined with "resize/crop".
Diffstat (limited to 'src')
-rw-r--r-- | src/http/modules/ngx_http_image_filter_module.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/http/modules/ngx_http_image_filter_module.c b/src/http/modules/ngx_http_image_filter_module.c index f0c711e29..66ed34541 100644 --- a/src/http/modules/ngx_http_image_filter_module.c +++ b/src/http/modules/ngx_http_image_filter_module.c @@ -1262,7 +1262,11 @@ ngx_http_image_filter(ngx_conf_t *cf, ngx_command_t *cmd, void *conf) } else if (cf->args->nelts == 3) { if (ngx_strcmp(value[i].data, "rotate") == 0) { - imcf->filter = NGX_HTTP_IMAGE_ROTATE; + if (imcf->filter != NGX_HTTP_IMAGE_RESIZE + && imcf->filter != NGX_HTTP_IMAGE_CROP) + { + imcf->filter = NGX_HTTP_IMAGE_ROTATE; + } ngx_memzero(&ccv, sizeof(ngx_http_compile_complex_value_t)); |