mirror of
https://github.com/reactos/reactos.git
synced 2024-10-05 08:54:40 +00:00
- Return early if ProtocolNumber is too large
- Fixes coverity error 600 svn path=/branches/aicom-network-fixes/; revision=36525
This commit is contained in:
parent
d8398cc719
commit
9023e12475
|
@ -352,10 +352,10 @@ VOID IPRegisterProtocol(
|
|||
* To unregister a protocol handler, call this function with Handler = NULL
|
||||
*/
|
||||
{
|
||||
#ifdef DBG
|
||||
if (ProtocolNumber >= IP_PROTOCOL_TABLE_SIZE)
|
||||
if (ProtocolNumber >= IP_PROTOCOL_TABLE_SIZE) {
|
||||
TI_DbgPrint(MIN_TRACE, ("Protocol number is out of range (%d).\n", ProtocolNumber));
|
||||
#endif
|
||||
return;
|
||||
}
|
||||
|
||||
ProtocolTable[ProtocolNumber] = Handler;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue