5 Jun
2024
5 Jun
'24
7:56 a.m.
On Tue Jun 4 14:47:33 2024 +0000, Fabian Maurer wrote:
Is wcsdup compatible with CoTaskMemFree? I thought that you have to need to use CoTaskMemAlloc when you later want CoTaskMemFree (like MSDN says). No. We'd use `wcsdup()` / `free()` in the setter and only use `CoTaskMemAlloc()` when we actually need to return something. So that means not using `duplicate_wstr()` in the setters and instead calling `free()` and `wcsdup()` directly.
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/5773#note_72425