dxdiagn: PhysicalMemory parameter is a string not long long

Rob Shearman robertshearman at gmail.com
Sat Jun 21 03:01:08 CDT 2008


2008/6/21 Vitaliy Margolen <wine-patches at kievinfo.com>:
> @@ -300,6 +300,7 @@ static HRESULT DXDiag_InitDXDiagSystemInfoContainer(IDxDiagContainer* pSubCont)
>    GlobalMemoryStatusEx( &msex );
>    V_VT(&v) = VT_UI8;
>    V_UI8(&v) = msex.ullTotalPhys;
> +  VariantChangeType(&v, &v, 0, VT_BSTR);
>    IDxDiagContainerImpl_AddProp(pSubCont, ullPhysicalMemory, &v);
>
>    info.dwOSVersionInfoSize = sizeof(info);

You need to call VariantClear otherwise you will leak memory.

-- 
Rob Shearman



More information about the wine-devel mailing list