From 461412352d490d2c543791d37278e99f2c36d395 Mon Sep 17 00:00:00 2001 From: Willem Jan Withagen Date: Thu, 28 Jan 2021 01:00:45 +0100 Subject: [PATCH] librbd: Fix variable declaration in capture list in lambda Signed-off-by: Willem Jan Withagen --- src/librbd/migration/QCOWFormat.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/librbd/migration/QCOWFormat.cc b/src/librbd/migration/QCOWFormat.cc index 0499fa2a97c2f..4dfbbf0944caa 100644 --- a/src/librbd/migration/QCOWFormat.cc +++ b/src/librbd/migration/QCOWFormat.cc @@ -718,7 +718,7 @@ private: previous_l2_table = l2_table; l2_table.reset(); - auto ctx = new LambdaContext([this, snap_id](int r) { + auto ctx = new LambdaContext([this, snap_id = snap_id](int r) { boost::asio::post(qcow_format->m_strand, [this, snap_id, r]() { handle_get_l2_table(r, snap_id); }); -- 2.39.5