fixeria has uploaded this change for review. (
https://gerrit.osmocom.org/c/osmo-bsc/+/28425 )
Change subject: ipaccess-config: check value returned by abis_nm_tlv_parse()
......................................................................
ipaccess-config: check value returned by abis_nm_tlv_parse()
Change-Id: I38cd35506964efb1441555d16cea998f415e9394
Fixes: CID#272995
---
M src/ipaccess/ipaccess-config.c
1 file changed, 4 insertions(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/25/28425/1
diff --git a/src/ipaccess/ipaccess-config.c b/src/ipaccess/ipaccess-config.c
index 76f10f5..1d8675e 100644
--- a/src/ipaccess/ipaccess-config.c
+++ b/src/ipaccess/ipaccess-config.c
@@ -286,7 +286,10 @@
unsigned int indent = 0;
- abis_nm_tlv_parse(&tp, bts, foh->data, oh->length-sizeof(*foh));
+ if (abis_nm_tlv_parse(&tp, bts, foh->data, oh->length-sizeof(*foh)) < 0) {
+ LOGPFOH(DNM, LOGL_ERROR, foh, "%s(): tlv_parse failed\n", __func__);
+ return -EINVAL;
+ }
abis_nm_tlv_attr_primary_oml(&tp, &ia, &oml_port);
osmo_strlcpy(oml_ip, inet_ntoa(ia), sizeof(oml_ip));
--
To view, visit
https://gerrit.osmocom.org/c/osmo-bsc/+/28425
To unsubscribe, or for help writing mail filters, visit
https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I38cd35506964efb1441555d16cea998f415e9394
Gerrit-Change-Number: 28425
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-MessageType: newchange