diff --git a/source/Lib/EncoderLib/EncCu.cpp b/source/Lib/EncoderLib/EncCu.cpp
index 9aefa9b4be7a795c22cf1270d363f527c5547be9..92d455bb7f2aa086e154a56d40dff93ccd326518 100644
--- a/source/Lib/EncoderLib/EncCu.cpp
+++ b/source/Lib/EncoderLib/EncCu.cpp
@@ -1301,7 +1301,6 @@ void EncCu::xCheckModeSplit(CodingStructure *&tempCS, CodingStructure *&bestCS,
 #endif
         m_CurrCtx--;
         partitioner.exitCurrSplit();
-        bool bestCSUpdated =
         xCheckBestMode( tempCS, bestCS, partitioner, encTestMode );
         return;
       }
@@ -1433,7 +1432,6 @@ void EncCu::xCheckModeSplit(CodingStructure *&tempCS, CodingStructure *&bestCS,
 #endif
 
   // RD check for sub partitioned coding structure.
-  bool bestCSUpdated =
   xCheckBestMode( tempCS, bestCS, partitioner, encTestMode );
 
   if (isAffMVInfoSaved)