Change in osmo-bsc[master]: create only one SCCP user per SCCP instance

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

neels gerrit-no-reply at lists.osmocom.org
Tue May 26 23:58:39 UTC 2020


neels has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bsc/+/18504 )


Change subject: create only one SCCP user per SCCP instance
......................................................................

create only one SCCP user per SCCP instance

Depends: I9ecbab16b45268f626950303d6ff8296dd6acda0 (libosmo-sccp)
Change-Id: I6a2710edeb9ba047ae70e6b49d4c2e5f06d41a4e
---
M src/osmo-bsc/osmo_bsc_sigtran.c
1 file changed, 6 insertions(+), 2 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/04/18504/1

diff --git a/src/osmo-bsc/osmo_bsc_sigtran.c b/src/osmo-bsc/osmo_bsc_sigtran.c
index cbf0fec..f5489e4 100644
--- a/src/osmo-bsc/osmo_bsc_sigtran.c
+++ b/src/osmo-bsc/osmo_bsc_sigtran.c
@@ -547,8 +547,12 @@
 		LOGP(DMSC, LOGL_NOTICE, "(%s) A-interface: remote (MSC) SCCP address: %s\n",
 		     msc_name, osmo_sccp_inst_addr_name(msc->a.sccp, &msc->a.msc_addr));
 
-		/* Bind SCCP user */
-		msc->a.sccp_user = osmo_sccp_user_bind(msc->a.sccp, msc_name, sccp_sap_up, msc->a.bsc_addr.ssn);
+		/* Bind SCCP user. Bind only one user per sccp_instance. */
+		msc->a.sccp_user = osmo_sccp_user_find(msc->a.sccp, msc->a.bsc_addr.ssn, msc->a.bsc_addr.pc);
+		LOGP(DMSC, LOGL_NOTICE, "(%s) A-interface: %s\n", msc_name,
+		     msc->a.sccp_user ? "user already bound for this SCCP instance" : "binding SCCP user");
+		if (!msc->a.sccp_user)
+			msc->a.sccp_user = osmo_sccp_user_bind(msc->a.sccp, msc_name, sccp_sap_up, msc->a.bsc_addr.ssn);
 		if (!msc->a.sccp_user)
 			return -EINVAL;
 

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/18504
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I6a2710edeb9ba047ae70e6b49d4c2e5f06d41a4e
Gerrit-Change-Number: 18504
Gerrit-PatchSet: 1
Gerrit-Owner: neels <nhofmeyr at sysmocom.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20200526/3bd80669/attachment.htm>


More information about the gerrit-log mailing list