diff src/video/wincommon/SDL_sysevents.c @ 36:13ee9f4834ea

Windows CE patches contributed by Rainer Loritz
author Sam Lantinga <slouken@lokigames.com>
date Wed, 23 May 2001 23:35:10 +0000
parents e30a8ce27c22
children 994ed1d668e7
line wrap: on
line diff
--- a/src/video/wincommon/SDL_sysevents.c	Wed May 23 00:36:17 2001 +0000
+++ b/src/video/wincommon/SDL_sysevents.c	Wed May 23 23:35:10 2001 +0000
@@ -496,12 +496,12 @@
 #ifdef _WIN32_WCE
     {
 	/* WinCE uses the UNICODE version */
-	int nLen = strlen(name);
-	LPWSTR lpszW = alloca((nLen+1)*2);
+	int nLen = strlen(name)+1;
+	LPWSTR lpszW = alloca(nLen*2);
 	MultiByteToWideChar(CP_ACP, 0, name, -1, lpszW, nLen);
 	class.hIcon		= LoadImage(hInst, lpszW, IMAGE_ICON,
 	                                    0, 0, LR_DEFAULTCOLOR);
-	class.lpszMenuName	= lpszW;
+	class.lpszMenuName	= NULL;
 	class.lpszClassName	= lpszW;
     }
 #else