From 65a2b35f09539b17cd5a9367492a014aa3c59a94 Mon Sep 17 00:00:00 2001 From: Pedro Alvarez Date: Thu, 23 Sep 2021 14:13:07 +0100 Subject: [PATCH] Fix not checking initialization of S11 in MME. Fixed typo. --- lib/test/common/network_utils_test.cc | 4 ++-- srsepc/src/mme/s1ap.cc | 4 ++++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/lib/test/common/network_utils_test.cc b/lib/test/common/network_utils_test.cc index c63fd97e3..31fbe2b4c 100644 --- a/lib/test/common/network_utils_test.cc +++ b/lib/test/common/network_utils_test.cc @@ -122,8 +122,8 @@ int test_sctp_bind_error() &sock, srsran::net_utils::socket_type::seqpacket, "1.1.1.1", 8000)); // Bogus IP address // should not be able to bind TESTASSERT(srsran::net_utils::sctp_init_socket( - &sock, srsran::net_utils::socket_type::seqpacket, "127.0.0.1", 8000)); // Bogus IP address - // should not be able to bind + &sock, srsran::net_utils::socket_type::seqpacket, "127.0.0.1", 8000)); // Good IP address + // should be able to bind return SRSRAN_SUCCESS; } diff --git a/srsepc/src/mme/s1ap.cc b/srsepc/src/mme/s1ap.cc index b652198c0..9b901ddf8 100644 --- a/srsepc/src/mme/s1ap.cc +++ b/srsepc/src/mme/s1ap.cc @@ -78,8 +78,12 @@ int s1ap::init(const s1ap_args_t& s1ap_args) // Get pointer to GTP-C class m_mme_gtpc = mme_gtpc::get_instance(); + // Initialize S1-MME m_s1mme = enb_listen(); + if (m_s1mme == SRSRAN_ERROR) { + return SRSRAN_ERROR; + } // Init PCAP m_pcap_enable = s1ap_args.pcap_enable;