mirror of
https://github.com/nginx/nginx.git
synced 2024-11-27 23:49:00 +08:00
merge r3488:
revert partially r1555 and fix the error "memcached sent invalid trailer"
This commit is contained in:
parent
6b2bcfcd0d
commit
7fbe27b79f
@ -423,15 +423,20 @@ ngx_http_memcached_filter(void *data, ssize_t bytes)
|
||||
|
||||
if (ngx_strncmp(b->last,
|
||||
ngx_http_memcached_end + NGX_HTTP_MEMCACHED_END - ctx->rest,
|
||||
ctx->rest)
|
||||
bytes)
|
||||
!= 0)
|
||||
{
|
||||
ngx_log_error(NGX_LOG_ERR, ctx->request->connection->log, 0,
|
||||
"memcached sent invalid trailer");
|
||||
|
||||
u->length = 0;
|
||||
ctx->rest = 0;
|
||||
|
||||
return NGX_OK;
|
||||
}
|
||||
|
||||
u->length = 0;
|
||||
ctx->rest = 0;
|
||||
u->length -= bytes;
|
||||
ctx->rest -= bytes;
|
||||
|
||||
return NGX_OK;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user