mirror of
https://github.com/scylladb/scylladb.git
synced 2026-04-20 16:40:35 +00:00
If we move altered inside this lambda, the next invocations of the outter lambda will see a corrupted value. So in the case of smp, invoke_on_all will invoke correctly in the first shard, but then see a bogus altered vector on the subsequent ones. Capturing a reference is fine, because the outer lambda will not be destroyed until the inner one completes - so the object will live in the capture list. Signed-off-by: Glauber Costa <glommer@cloudius-systems.com>