From 546ee988796276add05ce5b5d427176295725373 Mon Sep 17 00:00:00 2001 From: Francisco Paisana Date: Fri, 15 Nov 2019 12:23:18 +0000 Subject: [PATCH] fixed small issue that was causing compilation errors --- lib/include/srslte/common/network_utils.h | 5 +++++ lib/src/common/network_utils.cc | 4 ++-- srsenb/src/stack/upper/s1ap.cc | 4 ---- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/lib/include/srslte/common/network_utils.h b/lib/include/srslte/common/network_utils.h index 01eddd39e..80ec234fd 100644 --- a/lib/include/srslte/common/network_utils.h +++ b/lib/include/srslte/common/network_utils.h @@ -117,6 +117,11 @@ int tcp_send(int remotefd, const void* buf, size_t nbytes, srslte::log* log_); * Rx multisocket handler ***************************/ +/** + * Description - Instantiates a thread that will block waiting for IO from multiple sockets, via a select + * The user can register their own (socket fd, data handler) in this class via the + * add_socket_handler(fd, task) API or its other variants + */ class rx_multisocket_handler final : public thread { public: diff --git a/lib/src/common/network_utils.cc b/lib/src/common/network_utils.cc index f2e85fa80..7eb1b9cf0 100644 --- a/lib/src/common/network_utils.cc +++ b/lib/src/common/network_utils.cc @@ -485,10 +485,10 @@ bool rx_multisocket_handler::add_socket_pdu_handler(int fd, recv_callback_t pdu_ /** * Convenience method for reading PDUs from SCTP socket */ -bool rx_multisocket_handler::add_socket_sctp_pdu_handler(int fd, sctp_recv_callback_t task) +bool rx_multisocket_handler::add_socket_sctp_pdu_handler(int fd, sctp_recv_callback_t pdu_task) { srslte::rx_multisocket_handler::task_callback_t task; - task.reset(new srslte::sctp_recvmsg_pdu_task(pool, log_h, std::move(task))); + task.reset(new srslte::sctp_recvmsg_pdu_task(pool, log_h, std::move(pdu_task))); return add_socket_handler(fd, std::move(task)); } diff --git a/srsenb/src/stack/upper/s1ap.cc b/srsenb/src/stack/upper/s1ap.cc index 4b096b00c..f65ad4f26 100644 --- a/srsenb/src/stack/upper/s1ap.cc +++ b/srsenb/src/stack/upper/s1ap.cc @@ -141,10 +141,6 @@ srslte::proc_outcome_t s1ap::s1_setup_proc_t::react(const srsenb::s1ap::s1_setup void s1ap::s1_setup_proc_t::then(const srslte::proc_state_t& result) const { if (result.is_error()) { - // If a connection to the MME was created, it has to be erased again - // if (s1ap_ptr->s1ap_socket.is_init()) { - // s1ap_ptr->stack->remove_mme_socket(s1ap_ptr->s1ap_socket.fd()); - // } s1ap_ptr->s1ap_socket.reset(); procInfo("S1AP socket closed.\n"); }