DrawTextEx should allocate text buffer on stack for thread safeness.

This commit is contained in:
Dmitry Timoshkov 2004-11-30 17:21:16 +00:00 committed by Alexandre Julliard
parent 7e11e528c1
commit ba0ee349e6
1 changed files with 3 additions and 3 deletions

View File

@ -846,7 +846,7 @@ INT WINAPI DrawTextExW( HDC hdc, LPWSTR str, INT i_count,
const WCHAR *strPtr;
WCHAR *retstr, *p_retstr;
size_t size_retstr;
static WCHAR line[MAX_STATIC_BUFFER];
WCHAR line[MAX_STATIC_BUFFER];
int len, lh, count=i_count;
TEXTMETRICW tm;
int lmargin = 0, rmargin = 0;
@ -858,8 +858,8 @@ INT WINAPI DrawTextExW( HDC hdc, LPWSTR str, INT i_count,
int prefix_offset;
ellipsis_data ellip;
TRACE("%s, %d, [(%ld,%ld),(%ld,%ld)]\n", debugstr_wn (str, count), count,
rect->left, rect->top, rect->right, rect->bottom);
TRACE("%s, %d, [%s] %08x\n", debugstr_wn (str, count), count,
wine_dbgstr_rect(rect), flags);
if (dtp) TRACE("Params: iTabLength=%d, iLeftMargin=%d, iRightMargin=%d\n",
dtp->iTabLength, dtp->iLeftMargin, dtp->iRightMargin);