[PATCH] fixed size passed to MBtoWC
Marcus Meissner
meissner at suse.de
Thu Sep 11 06:33:15 CDT 2008
---
dlls/shell32/cpanelfolder.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/dlls/shell32/cpanelfolder.c b/dlls/shell32/cpanelfolder.c
index d3934a0..10d2c9d 100644
--- a/dlls/shell32/cpanelfolder.c
+++ b/dlls/shell32/cpanelfolder.c
@@ -997,7 +997,7 @@ static HRESULT WINAPI IShellExecuteHookW_fnExecute(IShellExecuteHookW* iface, LP
path[0] = '\"';
/* Return value from MultiByteToWideChar includes terminating NUL, which
* compensates for the starting double quote we just put in */
- l = MultiByteToWideChar(CP_ACP, 0, pcpanel->szName, -1, path+1, MAX_PATH);
+ l = MultiByteToWideChar(CP_ACP, 0, pcpanel->szName, -1, path+1, MAX_PATH-1);
/* pass applet name to Control_RunDLL to distinguish between applets in one .cpl file */
path[l++] = '"';
--
1.5.6
More information about the wine-patches
mailing list