devenum: Fix order of operations bug (Coverity id 709).

This commit is contained in:
Juan Lang 2008-09-10 11:31:50 -07:00 committed by Alexandre Julliard
parent a8513a2113
commit df592b3c3a

View file

@ -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);