Index: branches/SHM-dev/source/Lib/TLibDecoder/TDecCAVLC.cpp
===================================================================
--- branches/SHM-dev/source/Lib/TLibDecoder/TDecCAVLC.cpp	(revision 914)
+++ branches/SHM-dev/source/Lib/TLibDecoder/TDecCAVLC.cpp	(revision 923)
@@ -770,4 +770,8 @@
   {
     READ_CODE( 3,  uiCode, "sps_ext_or_max_sub_layers_minus1" );     uiTmp = uiCode;
+    if(!( pcSPS->getLayerId() != 0 && uiTmp == 7 ))
+    {
+      pcSPS->setMaxTLayers(uiTmp+1);
+    }
   }
 #endif
