more HEAP_strdupAtoW removals

Rolf Kalbermatter r.kalbermatter at hccnet.nl
Thu Jan 23 08:42:10 CST 2003


Matthew Davison <m.davison at virgin.net> wrote:

>On Thu, 2003-01-23 at 01:36, Dmitry Timoshkov wrote:
>> > @@ -760,24 +774,26 @@
>> > BOOL WINAPI OpenPrinterA(LPSTR lpPrinterName,HANDLE *phPrinter,
>> > LPPRINTER_DEFAULTSA pDefault)
>> > {
>> > - LPWSTR lpPrinterNameW = HEAP_strdupAtoW(GetProcessHeap(),0,lpPrinterName);
>> > + UNICODE_STRING lpPrinterNameW;
>> > + UNICODE_STRING usBuffer;
>> > + RtlCreateUnicodeStringFromAsciiz(&lpPrinterNameW,lpPrinterName);
>> > PRINTER_DEFAULTSW DefaultW, *pDefaultW = NULL;
>> > BOOL ret;
>
>> Are you sure that mixed data declarations/function call will be accepted
>> by any C compiler out there? I doubt that even gcc will accept this.
>well, im pretty sure gcc takes this, but ill change it anyway.
>thanks.

And I can tell you that Visual C is happy to compile this if the file has
a .cpp ending but will bark for .c files ;-(.

Rolf Kalbermatter




More information about the wine-devel mailing list