Declare originalFlags inside lambda function

This commit fix the compilation error in lambda function as
"originalFlags" variable not declare in capture clause

Change-Id: Ic1099430276ecff1c552a78480f943bb41532463
Signed-off-by: PavanKumarIntel <pavanx.kumar.martha@intel.com>
diff --git a/callback-manager/src/callback_manager.cpp b/callback-manager/src/callback_manager.cpp
index aaa5ffc..9d67808 100644
--- a/callback-manager/src/callback_manager.cpp
+++ b/callback-manager/src/callback_manager.cpp
@@ -108,9 +108,9 @@
         ledsToSet.push_back(std::make_pair(okLedPath, false));
         for (const auto& ledPair : ledsToSet)
         {
-            std::ios_base::fmtflags originalFlags = std::cerr.flags();
             conn->async_method_call(
                 [ledPair](const boost::system::error_code ec) {
+                    std::ios_base::fmtflags originalFlags = std::cerr.flags();
                     if (ec)
                     {
                         std::cerr << "Cannot set " << ledPair.first << " to "