Author: akhaldi
Date: Tue Nov 10 12:11:10 2015
New Revision: 69861
URL:
http://svn.reactos.org/svn/reactos?rev=69861&view=rev
Log:
[USER32] Improve the check for item in MENU_FindItem().
Modified:
trunk/reactos/win32ss/user/user32/windows/menu.c
Modified: trunk/reactos/win32ss/user/user32/windows/menu.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/user/user32/window…
==============================================================================
--- trunk/reactos/win32ss/user/user32/windows/menu.c [iso-8859-1] (original)
+++ trunk/reactos/win32ss/user/user32/windows/menu.c [iso-8859-1] Tue Nov 10 12:11:10
2015
@@ -110,7 +110,7 @@
else
{
PITEM item = menu->rgItems ? DesktopPtrToUser(menu->rgItems) : NULL;
- for (i = 0; item, i < menu->cItems; i++, item++)
+ for (i = 0; item && (i < menu->cItems); i++, item++)
{
if (item->spSubMenu)
{