mirror of
https://github.com/reactos/reactos.git
synced 2025-08-06 09:52:56 +00:00
overrun of static array
Fix for Coverity error CID: 546 + 547. svn path=/trunk/; revision=36413
This commit is contained in:
parent
eb68ba4328
commit
db712aaf9b
1 changed files with 2 additions and 2 deletions
|
@ -61,7 +61,7 @@ InitStockObjects(void)
|
||||||
DWORD STDCALL
|
DWORD STDCALL
|
||||||
GetSysColor(int nIndex)
|
GetSysColor(int nIndex)
|
||||||
{
|
{
|
||||||
if(nIndex >= 0 && nIndex <= NUM_SYSCOLORS)
|
if(nIndex >= 0 && nIndex < NUM_SYSCOLORS)
|
||||||
{
|
{
|
||||||
return g_psi->SysColors[nIndex];
|
return g_psi->SysColors[nIndex];
|
||||||
}
|
}
|
||||||
|
@ -91,7 +91,7 @@ GetSysColorPen(int nIndex)
|
||||||
HBRUSH STDCALL
|
HBRUSH STDCALL
|
||||||
GetSysColorBrush(int nIndex)
|
GetSysColorBrush(int nIndex)
|
||||||
{
|
{
|
||||||
if(nIndex >= 0 && nIndex <= NUM_SYSCOLORS)
|
if(nIndex >= 0 && nIndex < NUM_SYSCOLORS)
|
||||||
{
|
{
|
||||||
return g_psi->SysColorBrushes[nIndex];
|
return g_psi->SysColorBrushes[nIndex];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue