Change in osmo-bsc[master]: LCLS: constify helper parameters

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/.

Max gerrit-no-reply at lists.osmocom.org
Tue Jan 8 14:15:41 UTC 2019


Max has uploaded this change for review. ( https://gerrit.osmocom.org/12485


Change subject: LCLS: constify helper parameters
......................................................................

LCLS: constify helper parameters

Related: OS#2487
Change-Id: I341f4ea172432b94e8e96919926a5fb6870c2a30
---
M include/osmocom/bsc/osmo_bsc_lcls.h
M src/osmo-bsc/osmo_bsc_lcls.c
2 files changed, 6 insertions(+), 6 deletions(-)



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

diff --git a/include/osmocom/bsc/osmo_bsc_lcls.h b/include/osmocom/bsc/osmo_bsc_lcls.h
index 3eaa589..c8b0ebd 100644
--- a/include/osmocom/bsc/osmo_bsc_lcls.h
+++ b/include/osmocom/bsc/osmo_bsc_lcls.h
@@ -29,7 +29,7 @@
 	LCLS_EV_OTHER_DEAD,
 };
 
-enum gsm0808_lcls_status lcls_get_status(struct gsm_subscriber_connection *conn);
+enum gsm0808_lcls_status lcls_get_status(const struct gsm_subscriber_connection *conn);
 
 void lcls_update_config(struct gsm_subscriber_connection *conn,
 			const uint8_t *config, const uint8_t *control);
diff --git a/src/osmo-bsc/osmo_bsc_lcls.c b/src/osmo-bsc/osmo_bsc_lcls.c
index 2d5a077..2e86643 100644
--- a/src/osmo-bsc/osmo_bsc_lcls.c
+++ b/src/osmo-bsc/osmo_bsc_lcls.c
@@ -47,7 +47,7 @@
  * Utility functions
  ***********************************************************************/
 
-enum gsm0808_lcls_status lcls_get_status(struct gsm_subscriber_connection *conn)
+enum gsm0808_lcls_status lcls_get_status(const struct gsm_subscriber_connection *conn)
 {
 	if (!conn->lcls.fi)
 		return GSM0808_LCLS_STS_NA;
@@ -86,7 +86,7 @@
 }
 
 static struct gsm_subscriber_connection *
-find_conn_with_same_gcr(struct gsm_subscriber_connection *conn_local)
+find_conn_with_same_gcr(const struct gsm_subscriber_connection *conn_local)
 {
 	struct gsm_network *net = conn_local->network;
 	struct gsm_subscriber_connection *conn_other;
@@ -159,7 +159,7 @@
 /* Update the connections LCLS configuration and return old/previous configuration.
  * \returns (staticallly allocated) old configuration; NULL if new config not supported */
 static struct osmo_lcls *update_lcls_cfg_csc(struct gsm_subscriber_connection *conn,
-					     struct osmo_lcls *new_cfg_csc)
+					     const struct osmo_lcls *new_cfg_csc)
 {
 	static struct osmo_lcls old_cfg_csc = { 0 };
 	old_cfg_csc.config = conn->lcls.config;
@@ -275,7 +275,7 @@
 				NULL, 0, 0, NULL);
 }
 
-static void lcls_break_local_switching(struct gsm_subscriber_connection *conn)
+static void lcls_break_local_switching(const struct gsm_subscriber_connection *conn)
 {
 	struct mgcp_conn_peer mdcx_info;
 
@@ -303,7 +303,7 @@
 	}
 }
 
-static bool lcls_enable_possible(struct gsm_subscriber_connection *conn)
+static bool lcls_enable_possible(const struct gsm_subscriber_connection *conn)
 {
 	struct gsm_subscriber_connection *other_conn = conn->lcls.other;
 	OSMO_ASSERT(other_conn);

-- 
To view, visit https://gerrit.osmocom.org/12485
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I341f4ea172432b94e8e96919926a5fb6870c2a30
Gerrit-Change-Number: 12485
Gerrit-PatchSet: 1
Gerrit-Owner: Max <msuraev at sysmocom.de>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190108/c450b01f/attachment.htm>


More information about the gerrit-log mailing list