# HG changeset patch # User Maxim Dounin # Date 1360465255 0 # Node ID b5601d23b61ea0169f77b372db344a7dbfa317c1 # Parent 1559423ec28ba9944011f3dab70a4d7674186fb0 Merge of r4947: xslt: prevented infinite loop. If XSLT transformation failed and error 500 was handled in the same location, an infinite loop occured that exhausted the stack. diff --git a/src/http/modules/ngx_http_xslt_filter_module.c b/src/http/modules/ngx_http_xslt_filter_module.c --- a/src/http/modules/ngx_http_xslt_filter_module.c +++ b/src/http/modules/ngx_http_xslt_filter_module.c @@ -307,7 +307,7 @@ ngx_http_xslt_send(ngx_http_request_t *r ctx->done = 1; if (b == NULL) { - return ngx_http_filter_finalize_request(r, NULL, + return ngx_http_filter_finalize_request(r, &ngx_http_xslt_filter_module, NGX_HTTP_INTERNAL_SERVER_ERROR); } @@ -315,7 +315,7 @@ ngx_http_xslt_send(ngx_http_request_t *r if (cln == NULL) { ngx_free(b->pos); - return ngx_http_filter_finalize_request(r, NULL, + return ngx_http_filter_finalize_request(r, &ngx_http_xslt_filter_module, NGX_HTTP_INTERNAL_SERVER_ERROR); }