user32: Initialize string buffer

Alistair Leslie-Hughes leslie_alistair at hotmail.com
Mon Nov 12 03:27:56 CST 2012


Hi Nikolay,

On 12/11/2012 8:39 PM, Nikolay Sivov wrote:
> On 11/12/2012 11:33, Alistair Leslie-Hughes wrote:
>> Hi,
>>
>> Should fix http://bugs.winehq.org/show_bug.cgi?id=28797
>>
>>
>> Changelog:
>>     user32: Initialize string buffer
> I think it could be GetWindowText problem actually, if it succeeded and
> left buffer uninitialized that could be a real bug here, so needs tests.
Yes, GetWindowText doesn't return a a NULL terminated string, so that it 
the cause of the uninitialized read.

Another solution is to use the return value from GetWindowText and pass 
that value through to DrawText, instead of the -1.

Best Regards
  Alistair Leslie-Hughes



More information about the wine-devel mailing list