ddraw: Don't interpret end padding as dwCaps2 for x64.

Alexandre Julliard julliard at winehq.org
Mon May 23 04:33:55 CDT 2011


Dylan Smith <dylan.ah.smith at gmail.com> writes:

> @@ -3123,6 +3123,8 @@ static HRESULT CreateSurface(IDirectDrawImpl *ddraw, DDSURFACEDESC2 *DDSD,
>      memset(&desc2, 0, sizeof(desc2));
>      desc2.dwSize = sizeof(desc2);   /* For the struct copy */
>      DD_STRUCT_COPY_BYSIZE(&desc2, DDSD);
> +    if (DDSD->dwSize == sizeof(DDSURFACEDESC))
> +        CLEAR_STRUCT_END_PADDING((DDSURFACEDESC*)&desc2, ddsCaps);

I'd suggest to rethink the whole thing. We don't really need to set the
same structure fields 4 times.

-- 
Alexandre Julliard
julliard at winehq.org



More information about the wine-devel mailing list