user32: In DrawTextW/A make sure to properly initialize the cbSize of DRAWTEXTPARAMS.

This commit is contained in:
Aric Stewart 2008-10-13 08:30:55 -05:00 committed by Alexandre Julliard
parent a504a79d65
commit 8b9ebc30c9
1 changed files with 2 additions and 0 deletions

View File

@ -1081,6 +1081,7 @@ INT WINAPI DrawTextW( HDC hdc, LPCWSTR str, INT count, LPRECT rect, UINT flags )
DRAWTEXTPARAMS dtp;
memset (&dtp, 0, sizeof(dtp));
dtp.cbSize = sizeof(dtp);
if (flags & DT_TABSTOP)
{
dtp.iTabLength = (flags >> 8) & 0xff;
@ -1097,6 +1098,7 @@ INT WINAPI DrawTextA( HDC hdc, LPCSTR str, INT count, LPRECT rect, UINT flags )
DRAWTEXTPARAMS dtp;
memset (&dtp, 0, sizeof(dtp));
dtp.cbSize = sizeof(dtp);
if (flags & DT_TABSTOP)
{
dtp.iTabLength = (flags >> 8) & 0xff;