diff options
| author | Tiejun Zhou <[email protected]> | 2022-12-16 08:18:00 +0000 |
|---|---|---|
| committer | Tiejun Zhou <[email protected]> | 2022-12-16 08:18:00 +0000 |
| commit | a2f77b468f03e0f407f0f6cd1a88d09e6cf5ca28 (patch) | |
| tree | 36d3162662f66c3f339a0a0de8d5d7313475ff4a /common | |
| parent | 5fcaeaa42c8efa29562f209e514c1b2298723ef0 (diff) | |
Update on 16 Dec 2022. Expand to see details.
d9cb7cecd Removed the invalid check which would disable the function of clearing tcp_re...
0bea4ec98 [CLOUD]Fixed event clear function.
c6efa9ff5 Update link in Azure IoT readme.md
6937eb06e [Telnet Server] Correct the processing of disconnection.
a54496588 add new ports (M55 and M85) to NetX Duo
f4db567a0 Fix the build issue caused by the macros of NetX Duo be defined in nx_port.h...
d1951f19b add cmakelists file for m33 gnu
f7b967807 fix whitespace
f4bd13119 Fixed the issue which caused by driver entry pointer is NULL.
606e89cde Update compatibility in update manifest for ADU test case
16e54e1f2 Correct compatibility property name to match the values in import manifest
1c69327b1 Cleared the client ID to fix the issue of creating FTP client after deletion.
Diffstat (limited to 'common')
| -rw-r--r-- | common/src/nx_ip_interface_status_check.c | 21 | ||||
| -rw-r--r-- | common/src/nxe_tcp_socket_receive_notify.c | 11 |
2 files changed, 24 insertions, 8 deletions
diff --git a/common/src/nx_ip_interface_status_check.c b/common/src/nx_ip_interface_status_check.c index 1edfc816..e45731c7 100644 --- a/common/src/nx_ip_interface_status_check.c +++ b/common/src/nx_ip_interface_status_check.c @@ -35,7 +35,7 @@ /* FUNCTION RELEASE */ /* */ /* _nx_ip_interface_status_check PORTABLE C */ -/* 6.1 */ +/* 6.x */ /* AUTHOR */ /* */ /* Yuxin Zhou, Microsoft Corporation */ @@ -79,6 +79,9 @@ /* 05-19-2020 Yuxin Zhou Initial Version 6.0 */ /* 09-30-2020 Yuxin Zhou Modified comment(s), */ /* resulting in version 6.1 */ +/* xx-xx-xxxx Yajun Xia Modified comment(s), */ +/* added driver entry check, */ +/* resulting in version 6.x */ /* */ /**************************************************************************/ UINT _nx_ip_interface_status_check(NX_IP *ip_ptr, UINT interface_index, ULONG needed_status, @@ -185,6 +188,14 @@ ULONG trace_timestamp; NX_TRACE_IN_LINE_INSERT(NX_TRACE_INTERNAL_IO_DRIVER_GET_STATUS, ip_ptr, 0, 0, 0, NX_TRACE_INTERNAL_EVENTS, 0, 0); /* Call link level driver. */ + if(ip_ptr -> nx_ip_interface[interface_index].nx_interface_link_driver_entry == NX_NULL) + { + + /* Release mutex protection. */ + tx_mutex_put(&(ip_ptr -> nx_ip_protection)); + + return(NX_NOT_SUCCESSFUL); + } (ip_ptr -> nx_ip_interface[interface_index].nx_interface_link_driver_entry)(&driver_request); /* If the driver does not recognize this keyword, we fall back to reading the IP link status.*/ @@ -254,6 +265,14 @@ ULONG trace_timestamp; NX_TRACE_IN_LINE_INSERT(NX_TRACE_INTERNAL_IO_DRIVER_GET_STATUS, ip_ptr, 0, 0, 0, NX_TRACE_INTERNAL_EVENTS, 0, 0); /* Call link level driver. */ + if(ip_ptr -> nx_ip_interface[interface_index].nx_interface_link_driver_entry == NX_NULL) + { + + /* Release mutex protection. */ + tx_mutex_put(&(ip_ptr -> nx_ip_protection)); + + return(NX_NOT_SUCCESSFUL); + } (ip_ptr -> nx_ip_interface[interface_index].nx_interface_link_driver_entry)(&driver_request); /* If the driver does not recognize this keyword, we fall back to reading the IP link status.*/ diff --git a/common/src/nxe_tcp_socket_receive_notify.c b/common/src/nxe_tcp_socket_receive_notify.c index e145110c..936efece 100644 --- a/common/src/nxe_tcp_socket_receive_notify.c +++ b/common/src/nxe_tcp_socket_receive_notify.c @@ -38,7 +38,7 @@ NX_CALLER_CHECKING_EXTERNS /* FUNCTION RELEASE */ /* */ /* _nxe_tcp_socket_receive_notify PORTABLE C */ -/* 6.1 */ +/* 6.x */ /* AUTHOR */ /* */ /* Yuxin Zhou, Microsoft Corporation */ @@ -75,6 +75,9 @@ NX_CALLER_CHECKING_EXTERNS /* 05-19-2020 Yuxin Zhou Initial Version 6.0 */ /* 09-30-2020 Yuxin Zhou Modified comment(s), */ /* resulting in version 6.1 */ +/* xx-xx-xxxx Yajun Xia Modified comment(s), */ +/* removed invalid check, */ +/* resulting in version 6.x */ /* */ /**************************************************************************/ UINT _nxe_tcp_socket_receive_notify(NX_TCP_SOCKET *socket_ptr, @@ -89,12 +92,6 @@ UINT status; return(NX_PTR_ERROR); } - /* Check for invalid input pointers. */ - if (tcp_receive_notify == NX_NULL) - { - return(NX_PTR_ERROR); - } - /* Check to see if TCP is enabled. */ if (!(socket_ptr -> nx_tcp_socket_ip_ptr) -> nx_ip_tcp_packet_receive) { |
