Merge pull request #1788 from openmv/winc_sock_close

drivers/winc1500: Set NIC to NULL on closing sockets.
This commit is contained in:
Ibrahim Abdelkader 2023-02-21 17:24:24 +02:00 committed by GitHub
commit d3930c1408
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -429,6 +429,7 @@ static void py_winc_socket_close(mod_network_socket_obj_t *socket)
socket->fileno = -1; // Mark socket FD as invalid socket->fileno = -1; // Mark socket FD as invalid
m_del(winc_socket_buf_t, socket->_private, 1); m_del(winc_socket_buf_t, socket->_private, 1);
socket->_private = NULL; socket->_private = NULL;
socket->nic = MP_OBJ_NULL;
} }
} }