librbd: Fix variable declaration in capture list in lambda

Fixes: https://github.com/ceph/ceph/pull/38000
Signed-off-by: Willem Jan Withagen <wjw@digiware.nl>
This commit is contained in:
Willem Jan Withagen 2020-11-21 22:58:13 +01:00
parent 8f26ecb35d
commit 80ae2d286c

View File

@ -105,7 +105,7 @@ void HttpStream<I>::read(io::Extents&& byte_extents, bufferlist* data,
req.set(boost::beast::http::field::range, range.str());
m_http_client->issue(std::move(req),
[this, byte_offset, byte_length, ctx](int r, HttpResponse&& response) {
[this, byte_offset=byte_offset, byte_length=byte_length, ctx](int r, HttpResponse&& response) {
handle_read(r, std::move(response), byte_offset, byte_length, &ctx->bl,
ctx);
});