Check index before access (#7795)
authorDmitry-Me <Dmitry-Me@users.noreply.github.com>
Tue, 25 Oct 2016 17:02:55 +0000 (20:02 +0300)
committerJan Vorlicek <janvorli@microsoft.com>
Tue, 25 Oct 2016 17:02:55 +0000 (19:02 +0200)
src/ToolBox/SOS/Strike/sildasm.cpp

index 6bd3bb4..911ff09 100644 (file)
@@ -789,7 +789,7 @@ PCCOR_SIGNATURE PrettyPrintType(
                         {   
                             //if (sizes[i] != 0 || lowerBounds[i] != 0)   
                             {   
-                                if (lowerBounds[i] == 0 && i < numSizes)    
+                                if (i < numSizes && lowerBounds[i] == 0)
                                     appendStrNum(out, sizes[i]);    
                                 else    
                                 {