Author: cwittich
Date: Tue Sep 23 02:38:00 2008
New Revision: 36413
URL:
http://svn.reactos.org/svn/reactos?rev=36413&view=rev
Log:
overrun of static array
Fix for Coverity error CID: 546 + 547.
Modified:
trunk/reactos/dll/win32/user32/windows/defwnd.c
Modified: trunk/reactos/dll/win32/user32/windows/defwnd.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/user32/windows/d…
==============================================================================
--- trunk/reactos/dll/win32/user32/windows/defwnd.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/user32/windows/defwnd.c [iso-8859-1] Tue Sep 23 02:38:00 2008
@@ -61,7 +61,7 @@
DWORD STDCALL
GetSysColor(int nIndex)
{
- if(nIndex >= 0 && nIndex <= NUM_SYSCOLORS)
+ if(nIndex >= 0 && nIndex < NUM_SYSCOLORS)
{
return g_psi->SysColors[nIndex];
}
@@ -91,7 +91,7 @@
HBRUSH STDCALL
GetSysColorBrush(int nIndex)
{
- if(nIndex >= 0 && nIndex <= NUM_SYSCOLORS)
+ if(nIndex >= 0 && nIndex < NUM_SYSCOLORS)
{
return g_psi->SysColorBrushes[nIndex];
}