u = r->upstream;
ctx = ngx_http_get_module_ctx(r, ngx_http_proxy_module);
+ if (ctx == NULL) {
+ return NGX_ERROR;
+ }
+
ngx_log_debug4(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
"http proxy filter init s:%d h:%d c:%d l:%O",
u->headers_in.status_n, ctx->head, u->headers_in.chunked,
} state;
ctx = ngx_http_get_module_ctx(r, ngx_http_proxy_module);
+
+ if (ctx == NULL) {
+ return NGX_ERROR;
+ }
+
state = ctx->state;
if (state == sw_chunk_data && ctx->size == 0) {
r = p->input_ctx;
ctx = ngx_http_get_module_ctx(r, ngx_http_proxy_module);
+ if (ctx == NULL) {
+ return NGX_ERROR;
+ }
+
b = NULL;
prev = &buf->shadow;
ngx_http_proxy_ctx_t *ctx;
ctx = ngx_http_get_module_ctx(r, ngx_http_proxy_module);
+
+ if (ctx == NULL) {
+ return NGX_ERROR;
+ }
+
u = r->upstream;
buf = &u->buffer;