devenum: Fix order of operations bug (Coverity id 709).
This commit is contained in:
parent
a8513a2113
commit
df592b3c3a
|
@ -191,7 +191,7 @@ static void DEVENUM_ReadPinTypes(HKEY hkeyPinKey, REGFILTERPINS *rgPin)
|
|||
|
||||
if (rgPin->nMediaTypes == dwMediaTypeSize)
|
||||
{
|
||||
DWORD dwNewSize = dwMediaTypeSize + (dwMediaTypeSize < 2) ? 1 : dwMediaTypeSize / 2;
|
||||
DWORD dwNewSize = dwMediaTypeSize + (dwMediaTypeSize < 2 ? 1 : dwMediaTypeSize / 2);
|
||||
REGPINTYPES *lpNewMediaType;
|
||||
|
||||
lpNewMediaType = CoTaskMemRealloc(lpMediaType, sizeof(REGPINTYPES) * dwNewSize);
|
||||
|
|
Loading…
Reference in New Issue