[PATCH 2/5] mpr: Implement provider selection given remote name.
Pierre Schweitzer
pierre at reactos.org
Tue Aug 2 07:17:20 CDT 2016
Le 02/08/2016 à 14:13, Nikolay Sivov a écrit :
> On 02.08.2016 14:31, Pierre Schweitzer wrote:
>> + len = WideCharToMultiByte(CP_ACP, 0, provider->lpProvider, -1, NULL, 0, NULL, NULL);
>> + provider_name = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR));
>> + if (provider_name)
>> + memcpy(provider_name, provider->lpProvider, len * sizeof(WCHAR));
>> +
>> + HeapFree(GetProcessHeap(), 0, provider);
>> +
>> + return provider_name;
>
> This is confusing. WNetGetResourceInformationW return W string, you
> convert it to A, and use A length to allocate another W buffer? What's
> going on?
I'm just getting string length for a local recopy, as it is done in
other places.
Should I use something else? Like some strdupW if it exists?
--
Pierre Schweitzer <pierre at reactos.org>
System & Network Administrator
Senior Kernel Developer
ReactOS Deutschland e.V.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 3960 bytes
Desc: Signature cryptographique S/MIME
URL: <http://www.winehq.org/pipermail/wine-devel/attachments/20160802/ad0c4639/attachment.bin>
More information about the wine-devel
mailing list