mirror of
https://github.com/nginx/nginx.git
synced 2024-12-20 14:13:33 -06:00
fix empty string replacement in sub_filter
This commit is contained in:
parent
fa928a6c66
commit
d13045f16c
@ -369,9 +369,14 @@ ngx_http_sub_body_filter(ngx_http_request_t *r, ngx_chain_t *in)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
b->memory = 1;
|
if (ctx->sub.len) {
|
||||||
b->pos = ctx->sub.data;
|
b->memory = 1;
|
||||||
b->last = ctx->sub.data + ctx->sub.len;
|
b->pos = ctx->sub.data;
|
||||||
|
b->last = ctx->sub.data + ctx->sub.len;
|
||||||
|
|
||||||
|
} else {
|
||||||
|
b->sync = 1;
|
||||||
|
}
|
||||||
|
|
||||||
cl->buf = b;
|
cl->buf = b;
|
||||||
cl->next = NULL;
|
cl->next = NULL;
|
||||||
|
Loading…
Reference in New Issue
Block a user