Module: wine Branch: master Commit: 2fdccc247e7ad136f30f8cabcb0fc1143ab37bf3 URL: http://source.winehq.org/git/wine.git/?a=commit;h=2fdccc247e7ad136f30f8cabcb...
Author: Sebastian Lackner sebastian@fds-team.de Date: Wed Oct 21 00:52:51 2015 +0200
gdiplus: Use the correct memory allocation function for PropVariants.
Signed-off-by: Sebastian Lackner sebastian@fds-team.de Signed-off-by: Dmitry Timoshkov dmitry@baikal.ru Signed-off-by: Vincent Povirk vincent@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/gdiplus/image.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/dlls/gdiplus/image.c b/dlls/gdiplus/image.c index 6725de8..1cef100 100644 --- a/dlls/gdiplus/image.c +++ b/dlls/gdiplus/image.c @@ -3065,7 +3065,7 @@ static BOOL get_bool_property(IWICMetadataReader *reader, const GUID *guid, cons PropVariantInit(&value);
id.vt = VT_LPWSTR; - id.u.pwszVal = HeapAlloc(GetProcessHeap(), 0, (lstrlenW(prop_name) + 1) * sizeof(WCHAR)); + id.u.pwszVal = CoTaskMemAlloc((lstrlenW(prop_name) + 1) * sizeof(WCHAR)); if (!id.u.pwszVal) return FALSE; lstrcpyW(id.u.pwszVal, prop_name); hr = IWICMetadataReader_GetValue(reader, NULL, &id, &value); @@ -3092,7 +3092,7 @@ static PropertyItem *get_property(IWICMetadataReader *reader, const GUID *guid, PropVariantInit(&value);
id.vt = VT_LPWSTR; - id.u.pwszVal = HeapAlloc(GetProcessHeap(), 0, (lstrlenW(prop_name) + 1) * sizeof(WCHAR)); + id.u.pwszVal = CoTaskMemAlloc((lstrlenW(prop_name) + 1) * sizeof(WCHAR)); if (!id.u.pwszVal) return NULL; lstrcpyW(id.u.pwszVal, prop_name); hr = IWICMetadataReader_GetValue(reader, NULL, &id, &value);