[PATCH 4/5] d2d1: Implement RegisterEffectFromString().

Nikolay Sivov nsivov at codeweavers.com
Mon Jun 6 03:37:09 CDT 2022



On 6/6/22 10:35, Ziqing Hui wrote:
> +    size = sizeof(*property_xml) * (wcslen(property_xml) + 1);
> +    hglobal = GlobalAlloc(0, size);
> +    data = GlobalLock(hglobal);
> +    memcpy(data, property_xml, size);
> +    GlobalUnlock(hglobal);
> +
> +    if (FAILED(hr = CreateStreamOnHGlobal(hglobal, TRUE, &stream)))
> +        return hr;
Seems easier to write whole string in a stream, and seek back.



More information about the wine-devel mailing list