diff --git a/components/rgbd-sources/src/algorithms/fixstars_sgm.cpp b/components/rgbd-sources/src/algorithms/fixstars_sgm.cpp
index 347d66184c3c32186594f2fd962046adcfb87883..71f714c3afd06c7c0b362d7b0f635efcf4dd808b 100644
--- a/components/rgbd-sources/src/algorithms/fixstars_sgm.cpp
+++ b/components/rgbd-sources/src/algorithms/fixstars_sgm.cpp
@@ -38,7 +38,7 @@ FixstarsSGM::FixstarsSGM(nlohmann::json &config) : Disparity(config) {
 	}
 	
 #ifdef HAVE_OPTFLOW
-	bool use_off_ = value("use_off", false);
+	use_off_ = value("use_off", false);
 
 	if (use_off_)
 	{