Dylan Smith : wordpad: Provide buffer for replace with text.
Alexandre Julliard
julliard at winehq.org
Fri Jun 11 09:58:32 CDT 2010
Module: wine
Branch: master
Commit: 975dd904ef8c1ddf6c08ebe465cc382c073dd1a0
URL: http://source.winehq.org/git/wine.git/?a=commit;h=975dd904ef8c1ddf6c08ebe465cc382c073dd1a0
Author: Dylan Smith <dylan.ah.smith at gmail.com>
Date: Fri Jun 11 00:44:16 2010 -0400
wordpad: Provide buffer for replace with text.
---
programs/wordpad/wordpad.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/programs/wordpad/wordpad.c b/programs/wordpad/wordpad.c
index 0bf5d0c..3b8b6bc 100644
--- a/programs/wordpad/wordpad.c
+++ b/programs/wordpad/wordpad.c
@@ -1302,6 +1302,7 @@ static LRESULT handle_findmsg(LPFINDREPLACEW pFr)
static void dialog_find(LPFINDREPLACEW fr, BOOL replace)
{
static WCHAR findBuffer[MAX_STRING_LEN];
+ static WCHAR replaceBuffer[MAX_STRING_LEN];
/* Allow only one search/replace dialog to open */
if(hFindWnd != NULL)
@@ -1315,8 +1316,10 @@ static void dialog_find(LPFINDREPLACEW fr, BOOL replace)
fr->hwndOwner = hMainWnd;
fr->Flags = FR_HIDEUPDOWN;
fr->lpstrFindWhat = findBuffer;
+ fr->lpstrReplaceWith = replaceBuffer;
fr->lCustData = -1;
- fr->wFindWhatLen = MAX_STRING_LEN*sizeof(WCHAR);
+ fr->wFindWhatLen = sizeof(findBuffer);
+ fr->wReplaceWithLen = sizeof(replaceBuffer);
if(replace)
hFindWnd = ReplaceTextW(fr);
More information about the wine-cvs
mailing list