summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlpleahy <lpleahy@6f19259b-4bc3-4df7-8a09-765794883524>2011-09-28 01:55:00 +0000
committerlpleahy <lpleahy@6f19259b-4bc3-4df7-8a09-765794883524>2011-09-28 01:55:00 +0000
commit4f50efbebdfca33839d6d3f71eeaa02a72c3a213 (patch)
treeb871b2247a59a2f61cb1666b198c32f279ad7eb0
parentd3febe418b4d02f9304786b5aee2df41ee7fc873 (diff)
downloadedk2-4f50efbebdfca33839d6d3f71eeaa02a72c3a213.zip
edk2-4f50efbebdfca33839d6d3f71eeaa02a72c3a213.tar.gz
edk2-4f50efbebdfca33839d6d3f71eeaa02a72c3a213.tar.bz2
Merge more of the OptionGet and OptionSet routines into socket.c.
Fix the shutdown detection in OptionSet, bad pSocket pointer. Display the errors for OptionGet and OptionSet. Don't call BindTest during ListenComplete! Tested with: RawIp4Rx, RawIp4Tx, GetHostByName and WebServer. Signed-off by: Lee Leahy git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/branches/EADK@12463 6f19259b-4bc3-4df7-8a09-765794883524
-rw-r--r--StdLib/EfiSocketLib/Ip4.c103
-rw-r--r--StdLib/EfiSocketLib/Socket.c272
-rw-r--r--StdLib/EfiSocketLib/Socket.h9
-rw-r--r--StdLib/EfiSocketLib/Tcp4.c9
-rw-r--r--StdLib/EfiSocketLib/Udp4.c11
5 files changed, 213 insertions, 191 deletions
diff --git a/StdLib/EfiSocketLib/Ip4.c b/StdLib/EfiSocketLib/Ip4.c
index 7330ae3..2d34126 100644
--- a/StdLib/EfiSocketLib/Ip4.c
+++ b/StdLib/EfiSocketLib/Ip4.c
@@ -72,13 +72,16 @@ EslIp4LocalAddressGet (
number from the dynamic range. Specifying a specific
port number causes the network layer to use that port.
+ @param [in] bBindTest TRUE = run bind testing
+
@retval EFI_SUCCESS The operation was successful
**/
EFI_STATUS
EslIp4LocalAddressSet (
IN ESL_PORT * pPort,
- IN CONST struct sockaddr * pSockAddr
+ IN CONST struct sockaddr * pSockAddr,
+ IN BOOLEAN bBindTest
)
{
EFI_IP4_CONFIG_DATA * pConfig;
@@ -163,7 +166,6 @@ EslIp4LocalAddressSet (
the IPv4 options one at a time by name.
@param [in] pSocket Address of an ::ESL_SOCKET structure
- @param [in] level Option protocol level
@param [in] OptionName Name of the option
@param [out] ppOptionData Buffer to receive address of option value
@param [out] pOptionLength Buffer to receive the option length
@@ -174,7 +176,6 @@ EslIp4LocalAddressSet (
EFI_STATUS
EslIp4OptionGet (
IN ESL_SOCKET * pSocket,
- IN int level,
IN int OptionName,
OUT CONST void ** __restrict ppOptionData,
OUT socklen_t * __restrict pOptionLength
@@ -193,30 +194,19 @@ EslIp4OptionGet (
//
// Attempt to get the option
//
- switch ( level ) {
+ switch ( OptionName ) {
default:
//
- // Protocol level not supported
+ // Option not supported
//
pSocket->errno = ENOPROTOOPT;
Status = EFI_INVALID_PARAMETER;
break;
- case IPPROTO_IP:
- switch ( OptionName ) {
- default:
- //
- // Option not supported
- //
- pSocket->errno = ENOPROTOOPT;
- Status = EFI_INVALID_PARAMETER;
- break;
-
- case IP_HDRINCL:
- *ppOptionData = (void *)pSocket->bIncludeHeader;
- *pOptionLength = sizeof ( pSocket->bIncludeHeader );
- break;
- }
+ case IP_HDRINCL:
+ *ppOptionData = (void *)pSocket->bIncludeHeader;
+ *pOptionLength = sizeof ( pSocket->bIncludeHeader );
+ break;
}
//
@@ -236,7 +226,6 @@ EslIp4OptionGet (
the IPv4 options one at a time by name.
@param [in] pSocket Address of an ::ESL_SOCKET structure
- @param [in] level Option protocol level
@param [in] OptionName Name of the option
@param [in] pOptionValue Buffer containing the option value
@param [in] OptionLength Length of the buffer in bytes
@@ -247,7 +236,6 @@ EslIp4OptionGet (
EFI_STATUS
EslIp4OptionSet (
IN ESL_SOCKET * pSocket,
- IN int level,
IN int OptionName,
IN CONST void * pOptionValue,
IN socklen_t OptionLength
@@ -261,79 +249,51 @@ EslIp4OptionSet (
DBG_ENTER ( );
//
- // Assume failure
+ // Assume success
//
- pSocket->errno = EINVAL;
- Status = EFI_INVALID_PARAMETER;
+ pSocket->errno = 0;
+ Status = EFI_SUCCESS;
//
// Determine if the option protocol matches
//
LengthInBytes = 0;
pOptionData = NULL;
- switch ( level ) {
+ switch ( OptionName ) {
default:
//
// Protocol level not supported
//
- DEBUG (( DEBUG_INFO | DEBUG_OPTION, "ERROR - Invalid option level\r\n" ));
+ DEBUG (( DEBUG_INFO | DEBUG_OPTION, "ERROR - Invalid protocol option\r\n" ));
pSocket->errno = ENOTSUP;
Status = EFI_UNSUPPORTED;
break;
- case IPPROTO_IP:
- switch ( OptionName ) {
- default:
+ case IP_HDRINCL:
+
+ //
+ // Validate the option length
+ //
+ if ( sizeof ( UINT32 ) == OptionLength ) {
//
- // Protocol level not supported
+ // Restrict the input to TRUE or FALSE
//
- DEBUG (( DEBUG_INFO | DEBUG_OPTION, "ERROR - Invalid protocol option\r\n" ));
- pSocket->errno = ENOTSUP;
- Status = EFI_UNSUPPORTED;
- break;
-
- case IP_HDRINCL:
+ bTrueFalse = TRUE;
+ if ( 0 == *(UINT32 *)pOptionValue ) {
+ bTrueFalse = FALSE;
+ }
+ pOptionValue = &bTrueFalse;
//
- // Validate the option length
+ // Set the option value
//
- if ( sizeof ( UINT32 ) == OptionLength ) {
- //
- // Restrict the input to TRUE or FALSE
- //
- bTrueFalse = TRUE;
- if ( 0 == *(UINT32 *)pOptionValue ) {
- bTrueFalse = FALSE;
- }
- pOptionValue = &bTrueFalse;
-
- //
- // Set the option value
- //
- pOptionData = (UINT8 *)&pSocket->bIncludeHeader;
- LengthInBytes = sizeof ( pSocket->bIncludeHeader );
- }
- break;
-
+ pOptionData = (UINT8 *)&pSocket->bIncludeHeader;
+ LengthInBytes = sizeof ( pSocket->bIncludeHeader );
}
break;
}
//
- // Validate the option length
- //
- if ( LengthInBytes <= OptionLength ) {
- //
- // Set the option value
- //
- if ( NULL != pOptionData ) {
- CopyMem ( pOptionData, pOptionValue, LengthInBytes );
- pSocket->errno = 0;
- Status = EFI_SUCCESS;
- }
- }
-
- //
// Return the operation status
//
DBG_EXIT_STATUS ( Status );
@@ -1267,7 +1227,8 @@ EslIp4TxComplete (
code that supports SOCK_RAW sockets over IPv4.
**/
CONST ESL_PROTOCOL_API cEslIp4Api = {
- IPPROTO_IP,
+ "IPv4",
+ IPPROTO_IP,
OFFSET_OF ( ESL_PORT, Context.Ip4.ModeData.ConfigData ),
OFFSET_OF ( ESL_LAYER, pIp4List ),
OFFSET_OF ( struct sockaddr_in, sin_zero ),
diff --git a/StdLib/EfiSocketLib/Socket.c b/StdLib/EfiSocketLib/Socket.c
index 28e79f4..545c510 100644
--- a/StdLib/EfiSocketLib/Socket.c
+++ b/StdLib/EfiSocketLib/Socket.c
@@ -2681,9 +2681,16 @@ EslSocketOptionGet (
// Validate the socket
//
pSocket = NULL;
- if (( NULL != pSocketProtocol )
- && ( NULL != pOptionValue )
- && ( NULL != pOptionLength )) {
+ if ( NULL == pSocketProtocol ) {
+ DEBUG (( DEBUG_OPTION, "ERROR - pSocketProtocol is NULL!\r\n" ));
+ }
+ else if ( NULL == pOptionValue ) {
+ DEBUG (( DEBUG_OPTION, "ERROR - No option buffer specified\r\n" ));
+ }
+ else if ( NULL == pOptionLength ) {
+ DEBUG (( DEBUG_OPTION, "ERROR - Option length not specified!\r\n" ));
+ }
+ else {
pSocket = SOCKET_FROM_PROTOCOL ( pSocketProtocol );
LengthInBytes = 0;
MaxBytes = *pOptionLength;
@@ -2694,21 +2701,32 @@ EslSocketOptionGet (
// See if the protocol will handle the option
//
if ( NULL != pSocket->pApi->pfnOptionGet ) {
- Status = pSocket->pApi->pfnOptionGet ( pSocket,
- level,
- OptionName,
- &pOptionData,
- &LengthInBytes );
- errno = pSocket->errno;
+ if ( pSocket->pApi->DefaultProtocol == level ) {
+ Status = pSocket->pApi->pfnOptionGet ( pSocket,
+ OptionName,
+ &pOptionData,
+ &LengthInBytes );
+ errno = pSocket->errno;
+ break;
+ }
+ else {
+ //
+ // Protocol not supported
+ //
+ DEBUG (( DEBUG_OPTION,
+ "ERROR - The socket does not support this protocol!\r\n" ));
+ }
}
else {
//
// Protocol level not supported
//
- DEBUG (( DEBUG_INFO | DEBUG_OPTION, "ERROR - Invalid protocol option\r\n" ));
- errno = ENOPROTOOPT;
- Status = EFI_INVALID_PARAMETER;
+ DEBUG (( DEBUG_OPTION,
+ "ERROR - %a does not support any options!\r\n",
+ pSocket->pApi->pName ));
}
+ errno = ENOPROTOOPT;
+ Status = EFI_INVALID_PARAMETER;
break;
case SOL_SOCKET:
@@ -2717,7 +2735,7 @@ EslSocketOptionGet (
//
// Socket option not supported
//
- DEBUG (( DEBUG_INFO | DEBUG_OPTION, "ERROR - Invalid socket option\r\n" ));
+ DEBUG (( DEBUG_INFO | DEBUG_OPTION, "ERROR - Invalid socket option!\r\n" ));
errno = EINVAL;
Status = EFI_INVALID_PARAMETER;
break;
@@ -2787,13 +2805,17 @@ EslSocketOptionGet (
*pOptionLength = LengthInBytes;
//
- // Return the option value
+ // Determine if the option is present
//
- if ( NULL != pOptionData ) {
+ if ( 0 != LengthInBytes ) {
//
// Silently truncate the value length
//
if ( LengthInBytes > MaxBytes ) {
+ DEBUG (( DEBUG_OPTION,
+ "INFO - Truncating option from %d to %d bytes\r\n",
+ LengthInBytes,
+ MaxBytes ));
LengthInBytes = MaxBytes;
}
@@ -2872,123 +2894,155 @@ EslSocketOptionSet (
// Validate the socket
//
pSocket = NULL;
- if (( NULL != pSocketProtocol )
- && ( NULL != pOptionValue )
- && ( !pSocket->bRxDisable )
- && ( !pSocket->bTxDisable )) {
+ if ( NULL == pSocketProtocol ) {
+ DEBUG (( DEBUG_OPTION, "ERROR - pSocketProtocol is NULL!\r\n" ));
+ }
+ else if ( NULL == pOptionValue ) {
+ DEBUG (( DEBUG_OPTION, "ERROR - No option buffer specified\r\n" ));
+ }
+ else
+ {
pSocket = SOCKET_FROM_PROTOCOL ( pSocketProtocol );
- LengthInBytes = 0;
- pOptionData = NULL;
- switch ( level ) {
- default:
- //
- // See if the protocol will handle the option
- //
- if ( NULL != pSocket->pApi->pfnOptionSet ) {
- Status = pSocket->pApi->pfnOptionSet ( pSocket,
- level,
- OptionName,
- pOptionValue,
- OptionLength );
- errno = pSocket->errno;
- }
- else {
- //
- // Protocol level not supported
- //
- errno = ENOPROTOOPT;
- Status = EFI_INVALID_PARAMETER;
- }
- break;
-
- case SOL_SOCKET:
- switch ( OptionName ) {
+ if ( pSocket->bRxDisable || pSocket->bTxDisable ) {
+ DEBUG (( DEBUG_OPTION, "ERROR - Socket has been shutdown!\r\n" ));
+ }
+ else {
+ LengthInBytes = 0;
+ pOptionData = NULL;
+ switch ( level ) {
default:
//
- // Option not supported
+ // See if the protocol will handle the option
//
- errno = EINVAL;
+ if ( NULL != pSocket->pApi->pfnOptionSet ) {
+ if ( pSocket->pApi->DefaultProtocol == level ) {
+ Status = pSocket->pApi->pfnOptionSet ( pSocket,
+ OptionName,
+ pOptionValue,
+ OptionLength );
+ errno = pSocket->errno;
+ break;
+ }
+ else {
+ //
+ // Protocol not supported
+ //
+ DEBUG (( DEBUG_OPTION,
+ "ERROR - The socket does not support this protocol!\r\n" ));
+ }
+ }
+ else {
+ //
+ // Protocol level not supported
+ //
+ DEBUG (( DEBUG_OPTION,
+ "ERROR - %a does not support any options!\r\n",
+ pSocket->pApi->pName ));
+ }
+ errno = ENOPROTOOPT;
Status = EFI_INVALID_PARAMETER;
break;
+
+ case SOL_SOCKET:
+ switch ( OptionName ) {
+ default:
+ //
+ // Option not supported
+ //
+ DEBUG (( DEBUG_OPTION,
+ "ERROR - Sockets does not support this option!\r\n" ));
+ errno = EINVAL;
+ Status = EFI_INVALID_PARAMETER;
+ break;
- case SO_DEBUG:
- //
- // Set the debug flags
- //
- pOptionData = (UINT8 *)&pSocket->bOobInLine;
- LengthInBytes = sizeof ( pSocket->bOobInLine );
- break;
+ case SO_DEBUG:
+ //
+ // Set the debug flags
+ //
+ pOptionData = (UINT8 *)&pSocket->bOobInLine;
+ LengthInBytes = sizeof ( pSocket->bOobInLine );
+ break;
- case SO_OOBINLINE:
- pOptionData = (UINT8 *)&pSocket->bOobInLine;
- LengthInBytes = sizeof ( pSocket->bOobInLine );
+ case SO_OOBINLINE:
+ pOptionData = (UINT8 *)&pSocket->bOobInLine;
+ LengthInBytes = sizeof ( pSocket->bOobInLine );
- //
- // Validate the option length
- //
- if ( sizeof ( UINT32 ) == OptionLength ) {
//
- // Restrict the input to TRUE or FALSE
+ // Validate the option length
//
- bTrueFalse = TRUE;
- if ( 0 == *(UINT32 *)pOptionValue ) {
- bTrueFalse = FALSE;
+ if ( sizeof ( UINT32 ) == OptionLength ) {
+ //
+ // Restrict the input to TRUE or FALSE
+ //
+ bTrueFalse = TRUE;
+ if ( 0 == *(UINT32 *)pOptionValue ) {
+ bTrueFalse = FALSE;
+ }
+ pOptionValue = &bTrueFalse;
}
- pOptionValue = &bTrueFalse;
- }
- else {
+ else {
+ //
+ // Force an invalid option length error
+ //
+ OptionLength = LengthInBytes - 1;
+ }
+ break;
+
+ case SO_RCVTIMEO:
//
- // Force an invalid option length error
+ // Return the receive timeout
//
- OptionLength = LengthInBytes - 1;
- }
- break;
-
- case SO_RCVTIMEO:
- //
- // Return the receive timeout
- //
- pOptionData = (UINT8 *)&pSocket->RxTimeout;
- LengthInBytes = sizeof ( pSocket->RxTimeout );
- break;
+ pOptionData = (UINT8 *)&pSocket->RxTimeout;
+ LengthInBytes = sizeof ( pSocket->RxTimeout );
+ break;
- case SO_RCVBUF:
- //
- // Return the maximum receive buffer size
- //
- pOptionData = (UINT8 *)&pSocket->MaxRxBuf;
- LengthInBytes = sizeof ( pSocket->MaxRxBuf );
- break;
+ case SO_RCVBUF:
+ //
+ // Return the maximum receive buffer size
+ //
+ pOptionData = (UINT8 *)&pSocket->MaxRxBuf;
+ LengthInBytes = sizeof ( pSocket->MaxRxBuf );
+ break;
- case SO_SNDBUF:
- //
- // Send buffer size
- //
- //
- // Return the maximum transmit buffer size
- //
- pOptionData = (UINT8 *)&pSocket->MaxTxBuf;
- LengthInBytes = sizeof ( pSocket->MaxTxBuf );
+ case SO_SNDBUF:
+ //
+ // Send buffer size
+ //
+ //
+ // Return the maximum transmit buffer size
+ //
+ pOptionData = (UINT8 *)&pSocket->MaxTxBuf;
+ LengthInBytes = sizeof ( pSocket->MaxTxBuf );
+ break;
+ }
break;
}
- break;
- }
- //
- // Validate the option length
- //
- if ( LengthInBytes <= OptionLength ) {
//
- // Set the option value
+ // Determine if an option was found
//
- if ( NULL != pOptionData ) {
- CopyMem ( pOptionData, pOptionValue, LengthInBytes );
- errno = 0;
- Status = EFI_SUCCESS;
+ if ( 0 != LengthInBytes ) {
+ //
+ // Validate the option length
+ //
+ if ( LengthInBytes <= OptionLength ) {
+ //
+ // Set the option value
+ //
+ CopyMem ( pOptionData, pOptionValue, LengthInBytes );
+ errno = 0;
+ Status = EFI_SUCCESS;
+ }
+ else {
+ DEBUG (( DEBUG_OPTION,
+ "ERROR - Buffer to small, %d bytes < %d bytes!\r\n",
+ OptionLength,
+ LengthInBytes ));
+ }
}
}
}
-
+
//
// Return the operation status
//
@@ -3410,7 +3464,7 @@ EslSocketPortAllocate (
//
// Set the local address
//
- Status = pSocket->pApi->pfnLocalAddrSet ( pPort, pSockAddr );
+ Status = pSocket->pApi->pfnLocalAddrSet ( pPort, pSockAddr, bBindTest );
if ( EFI_ERROR ( Status )) {
break;
}
diff --git a/StdLib/EfiSocketLib/Socket.h b/StdLib/EfiSocketLib/Socket.h
index 5988106..372a15f 100644
--- a/StdLib/EfiSocketLib/Socket.h
+++ b/StdLib/EfiSocketLib/Socket.h
@@ -466,6 +466,7 @@ VOID
for the port causes the network layer to assign a port
number from the dynamic range. Specifying a specific
port number causes the network layer to use that port.
+ @param [in] bBindTest TRUE = run bind testing
@retval EFI_SUCCESS The operation was successful
@@ -474,7 +475,8 @@ typedef
EFI_STATUS
(* PFN_API_LOCAL_ADDR_SET) (
IN ESL_PORT * pPort,
- IN CONST struct sockaddr * pSockAddr
+ IN CONST struct sockaddr * pSockAddr,
+ IN BOOLEAN bBindTest
);
/**
@@ -514,7 +516,6 @@ EFI_STATUS
Retrieve the protocol options one at a time by name.
@param [in] pSocket Address of a ESL_SOCKET structure
- @param [in] level Option protocol level
@param [in] OptionName Name of the option
@param [out] ppOptionData Buffer to receive address of option value
@param [out] pOptionLength Buffer to receive the option length
@@ -526,7 +527,6 @@ typedef
EFI_STATUS
(* PFN_API_OPTION_GET) (
IN ESL_SOCKET * pSocket,
- IN int level,
IN int OptionName,
OUT CONST void ** __restrict ppOptionData,
OUT socklen_t * __restrict pOptionLength
@@ -538,7 +538,6 @@ EFI_STATUS
Adjust the protocol options one at a time by name.
@param [in] pSocket Address of a ESL_SOCKET structure
- @param [in] level Option protocol level
@param [in] OptionName Name of the option
@param [in] pOptionValue Buffer containing the option value
@param [in] OptionLength Length of the buffer in bytes
@@ -550,7 +549,6 @@ typedef
EFI_STATUS
(* PFN_API_OPTION_SET) (
IN ESL_SOCKET * pSocket,
- IN int level,
IN int OptionName,
IN CONST void * pOptionValue,
IN socklen_t OptionLength
@@ -825,6 +823,7 @@ VOID
This driver uses this structure to define the API for the socket type.
**/
typedef struct {
+ CONST CHAR8 * pName; ///< Protocol name
int DefaultProtocol; ///< Default protocol
UINTN ConfigDataOffset; ///< Offset in ::ESL_PORT to the configuration data
UINTN ServiceListOffset; ///< Offset in ::ESL_LAYER for the list of services
diff --git a/StdLib/EfiSocketLib/Tcp4.c b/StdLib/EfiSocketLib/Tcp4.c
index f2b3128..b66b30d 100644
--- a/StdLib/EfiSocketLib/Tcp4.c
+++ b/StdLib/EfiSocketLib/Tcp4.c
@@ -1097,13 +1097,16 @@ EslTcp4LocalAddressGet (
number from the dynamic range. Specifying a specific
port number causes the network layer to use that port.
+ @param [in] bBindTest TRUE = run bind testing
+
@retval EFI_SUCCESS The operation was successful
**/
EFI_STATUS
EslTcp4LocalAddressSet (
IN ESL_PORT * pPort,
- IN CONST struct sockaddr * pSockAddr
+ IN CONST struct sockaddr * pSockAddr,
+ IN BOOLEAN bBindTest
)
{
EFI_TCP4_ACCESS_POINT * pAccessPoint;
@@ -1160,7 +1163,8 @@ EslTcp4LocalAddressSet (
// Validate the IP address
//
pAccessPoint->StationPort = 0;
- Status = EslSocketBindTest ( pPort, EADDRNOTAVAIL );
+ Status = bBindTest ? EslSocketBindTest ( pPort, EADDRNOTAVAIL )
+ : EFI_SUCCESS;
if ( !EFI_ERROR ( Status )) {
//
// Set the port number
@@ -2198,6 +2202,7 @@ EslTcp4TxOobComplete (
over TCPv4.
**/
CONST ESL_PROTOCOL_API cEslTcp4Api = {
+ "TCPv4",
IPPROTO_TCP,
OFFSET_OF ( ESL_PORT, Context.Tcp4.ConfigData ),
OFFSET_OF ( ESL_LAYER, pTcp4List ),
diff --git a/StdLib/EfiSocketLib/Udp4.c b/StdLib/EfiSocketLib/Udp4.c
index 351fdf8..e1500d3 100644
--- a/StdLib/EfiSocketLib/Udp4.c
+++ b/StdLib/EfiSocketLib/Udp4.c
@@ -73,13 +73,16 @@ EslUdp4LocalAddressGet (
number from the dynamic range. Specifying a specific
port number causes the network layer to use that port.
+ @param [in] bBindTest TRUE = run bind testing
+
@retval EFI_SUCCESS The operation was successful
**/
EFI_STATUS
EslUdp4LocalAddressSet (
IN ESL_PORT * pPort,
- IN CONST struct sockaddr * pSockAddr
+ IN CONST struct sockaddr * pSockAddr,
+ IN BOOLEAN bBindTest
)
{
EFI_UDP4_CONFIG_DATA * pConfig;
@@ -101,8 +104,6 @@ EslUdp4LocalAddressSet (
pPort->pSocket->errno = EADDRNOTAVAIL;
}
else {
- Status = EFI_SUCCESS;
-
//
// Set the local address
//
@@ -139,7 +140,8 @@ EslUdp4LocalAddressSet (
// Validate the IP address
//
pConfig->StationPort = 0;
- Status = EslSocketBindTest ( pPort, EADDRNOTAVAIL );
+ Status = bBindTest ? EslSocketBindTest ( pPort, EADDRNOTAVAIL )
+ : EFI_SUCCESS;
if ( !EFI_ERROR ( Status )) {
//
// Set the port number
@@ -1017,6 +1019,7 @@ EslUdp4TxComplete (
code that supports SOCK_DGRAM sockets over UDPv4.
**/
CONST ESL_PROTOCOL_API cEslUdp4Api = {
+ "UDPv4",
IPPROTO_UDP,
OFFSET_OF ( ESL_PORT, Context.Udp4.ConfigData ),
OFFSET_OF ( ESL_LAYER, pUdp4List ),