summaryrefslogtreecommitdiff
path: root/src/ToolBox
diff options
context:
space:
mode:
authorOmair Majid <omajid@redhat.com>2019-04-16 23:18:37 -0400
committerJan Kotas <jkotas@microsoft.com>2019-04-16 20:18:37 -0700
commitdf2f4c4feb273545e91fd8d7d170dc424b741f19 (patch)
tree2d32739555da2bdf2acca03c6a74b535195b1e84 /src/ToolBox
parent97da6051f962014e7df0b7837fecbcdea0f9e248 (diff)
downloadcoreclr-df2f4c4feb273545e91fd8d7d170dc424b741f19.tar.gz
coreclr-df2f4c4feb273545e91fd8d7d170dc424b741f19.tar.bz2
coreclr-df2f4c4feb273545e91fd8d7d170dc424b741f19.zip
Fix a ZeroMemory call in methodcontext.cpp (#23843)
The argument is of type `GetArgTypeValue` and so the `sizeof()` should be done on `GetArgTypeValue`, not on the different type `GetArgType`.
Diffstat (limited to 'src/ToolBox')
-rw-r--r--src/ToolBox/superpmi/superpmi-shared/methodcontext.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ToolBox/superpmi/superpmi-shared/methodcontext.cpp b/src/ToolBox/superpmi/superpmi-shared/methodcontext.cpp
index a6b284488a..ebe7808ee5 100644
--- a/src/ToolBox/superpmi/superpmi-shared/methodcontext.cpp
+++ b/src/ToolBox/superpmi/superpmi-shared/methodcontext.cpp
@@ -2535,8 +2535,8 @@ void MethodContext::recGetArgType(CORINFO_SIG_INFO* sig,
GetArgType = new LightWeightMap<GetArgTypeValue, Agnostic_GetArgType_Value>();
GetArgTypeValue key;
- ZeroMemory(&key, sizeof(GetArgType)); // We use the input structs as a key and use memcmp to compare.. so
- // we need to zero out padding too
+ ZeroMemory(&key, sizeof(key)); // We use the input structs as a key and use memcmp to compare.. so
+ // we need to zero out padding too
// Only setting values for things the EE seems to pay attention to... this is necessary since some of the values
// are unset and fail our precise comparisons ...
key.flags = (DWORD)sig->flags;