From ea92064d38bfb62cfb30d67677380cd3d11ab8cd Mon Sep 17 00:00:00 2001 From: Gleb Natapov Date: Tue, 15 Mar 2016 16:53:27 +0200 Subject: [PATCH] avoid invoke_on_all during developer-mode application if possible Message-Id: <20160315145327.GW6117@scylladb.com> --- main.cc | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/main.cc b/main.cc index cc59cb4873..ffa46e40a7 100644 --- a/main.cc +++ b/main.cc @@ -347,11 +347,9 @@ int main(int ac, char** av) { using namespace locator; // Re-apply strict-dma after we've read the config file, this time // to all reactors - smp::invoke_on_all([devmode = opts.count("developer-mode")] { - if (devmode) { - engine().set_strict_dma(false); - } - }).get(); + if (opts.count("developer-mode")) { + smp::invoke_on_all([] { engine().set_strict_dma(false); }).get(); + } supervisor_notify("creating snitch"); i_endpoint_snitch::create_snitch(cfg->endpoint_snitch()).get(); // #293 - do not stop anything