Fix SOS DumpObj crash in DDRs
authorMike McLaughlin <mikem@microsoft.com>
Fri, 1 May 2015 18:05:40 +0000 (11:05 -0700)
committerMike McLaughlin <mikem@microsoft.com>
Fri, 1 May 2015 18:05:40 +0000 (11:05 -0700)
[tfs-changeset: 1463503]

src/ToolBox/SOS/Strike/util.cpp
src/inc/cortypeinfo.h

index fb0dd0c..2a012c1 100644 (file)
@@ -1014,7 +1014,7 @@ void DisplayDataMember (DacpFieldDescData* pFD, DWORD_PTR dwAddr, BOOL fAlign=TR
         DWORD_PTR dwTmp = dwAddr;
         bool bVTStatic = (pFD->bIsStatic && pFD->Type == ELEMENT_TYPE_VALUETYPE);
         
-        if (gElementTypeInfo[pFD->Type] != (DWORD)-1 || bVTStatic)
+        if (gElementTypeInfo[pFD->Type] != NO_SIZE || bVTStatic)
         {
             union Value
             {
index e35ae6f..443aeb5 100644 (file)
@@ -5,7 +5,7 @@
 
 // This describes information about the COM+ primitive types
 
-#define NO_SIZE 255
+#define NO_SIZE ((BYTE)-1)
 
 // TYPEINFO(type (CorElementType),  namespace, class,          size,           gcType,         isArray,isPrim, isFloat,isModifier,isGenVariable)