James Hawkins : user: Add missing sizeof(WCHAR) multiplier.
Alexandre Julliard
julliard at wine.codeweavers.com
Wed Oct 4 14:33:28 CDT 2006
Module: wine
Branch: master
Commit: 96963d2bc18aa8fc46aad623c6c122cfa8e4054c
URL: http://source.winehq.org/git/wine.git/?a=commit;h=96963d2bc18aa8fc46aad623c6c122cfa8e4054c
Author: James Hawkins <truiken at gmail.com>
Date: Wed Oct 4 03:16:23 2006 -0700
user: Add missing sizeof(WCHAR) multiplier.
---
dlls/user/dialog.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/dlls/user/dialog.c b/dlls/user/dialog.c
index c2f6d95..8934a54 100644
--- a/dlls/user/dialog.c
+++ b/dlls/user/dialog.c
@@ -1651,7 +1651,7 @@ static BOOL DIALOG_DlgDirSelect( HWND hw
size = SendMessageW(listbox, combo ? CB_GETLBTEXTLEN : LB_GETTEXTLEN, 0, 0 );
if (size == LB_ERR) return FALSE;
- if (!(buffer = HeapAlloc( GetProcessHeap(), 0, size+1 ))) return FALSE;
+ if (!(buffer = HeapAlloc( GetProcessHeap(), 0, (size+1) * sizeof(WCHAR) ))) return FALSE;
SendMessageW( listbox, combo ? CB_GETLBTEXT : LB_GETTEXT, item, (LPARAM)buffer );
More information about the wine-cvs
mailing list