|
|
@ -1,4 +1,4 @@
|
|
|
|
/* Copyright (C) 2007-2010 Open Information Security Foundation
|
|
|
|
/* Copyright (C) 2007-2020 Open Information Security Foundation
|
|
|
|
*
|
|
|
|
*
|
|
|
|
* You can copy, redistribute or modify this Program under the terms of
|
|
|
|
* You can copy, redistribute or modify this Program under the terms of
|
|
|
|
* the GNU General Public License version 2 as published by the Free
|
|
|
|
* the GNU General Public License version 2 as published by the Free
|
|
|
@ -93,17 +93,11 @@ void SCProtoNameInit()
|
|
|
|
* we have corresponding name entry for this number or not.
|
|
|
|
* we have corresponding name entry for this number or not.
|
|
|
|
*
|
|
|
|
*
|
|
|
|
* \param proto Protocol number to be validated
|
|
|
|
* \param proto Protocol number to be validated
|
|
|
|
* \retval ret On success returns TRUE otherwise FALSE
|
|
|
|
* \retval ret On success returns true otherwise false
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
uint8_t SCProtoNameValid(uint16_t proto)
|
|
|
|
bool SCProtoNameValid(uint16_t proto)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
uint8_t ret = FALSE;
|
|
|
|
return (proto <= 255 && known_proto[proto] != NULL);
|
|
|
|
|
|
|
|
|
|
|
|
if (proto <= 255 && known_proto[proto] != NULL) {
|
|
|
|
|
|
|
|
ret = TRUE;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return ret;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|