[PATCH] libosmocore[master]: Fix type of abis_nm_att_tlvdef_ipa variable

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

Ivan Kluchnikov gerrit-no-reply at lists.osmocom.org
Wed Feb 8 16:10:11 UTC 2017


Review at  https://gerrit.osmocom.org/1770

Fix type of abis_nm_att_tlvdef_ipa variable

abis_nm_att_tlvdef_ipa should not be a const, because this variable is modified by
tlv_def_patch function during initializing oml attribute definitions in osmo-bts code.
This bug was introduced during moving oml definitions from osmo-bts to libosmocore,
when type of abis_nm_att_tlvdef_ipa was changed from struct tlv_definition to const struct tlv_definition.

Change-Id: I57acf45bf5debe24c7ceb6c45ef0940e89e51a61
---
M include/osmocom/gsm/abis_nm.h
M src/gsm/abis_nm.c
2 files changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/70/1770/1

diff --git a/include/osmocom/gsm/abis_nm.h b/include/osmocom/gsm/abis_nm.h
index 14dbc08..0d81be3 100644
--- a/include/osmocom/gsm/abis_nm.h
+++ b/include/osmocom/gsm/abis_nm.h
@@ -34,7 +34,7 @@
 const char *abis_nm_avail_name(uint8_t avail);
 const char *abis_nm_test_name(uint8_t test);
 extern const struct tlv_definition abis_nm_osmo_att_tlvdef;
-extern const struct tlv_definition abis_nm_att_tlvdef_ipa;
+extern struct tlv_definition abis_nm_att_tlvdef_ipa;
 
 /*! \brief write a human-readable OML header to the debug log
  *  \param[in] ss Logging sub-system
diff --git a/src/gsm/abis_nm.c b/src/gsm/abis_nm.c
index 10aae9a..5dddde2 100644
--- a/src/gsm/abis_nm.c
+++ b/src/gsm/abis_nm.c
@@ -291,7 +291,7 @@
 };
 
 /*! \brief GSM A-bis OML IPA TLV parser definition */
-const struct tlv_definition abis_nm_att_tlvdef_ipa = {
+struct tlv_definition abis_nm_att_tlvdef_ipa = {
 	.def = {
 		/* ip.access specifics */
 		[NM_ATT_IPACC_DST_IP] =		{ TLV_TYPE_FIXED, 4 },

-- 
To view, visit https://gerrit.osmocom.org/1770
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I57acf45bf5debe24c7ceb6c45ef0940e89e51a61
Gerrit-PatchSet: 1
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Owner: Ivan Kluchnikov <kluchnikovi at gmail.com>



More information about the gerrit-log mailing list