aboutsummaryrefslogtreecommitdiffstats
path: root/src/osmo-bsc
diff options
context:
space:
mode:
authorPau Espin Pedrol <pespin@sysmocom.de>2020-10-16 12:08:49 +0200
committerpespin <pespin@sysmocom.de>2020-10-17 13:56:16 +0000
commit0aa489252d8fc57cd4a2d8f2a8702252be88abf8 (patch)
treea4430ff544d44f6837fb9fc21919660e5db42399 /src/osmo-bsc
parent60e5ddf65d50b3e430d29dd9b5cfdaf4d05f3204 (diff)
ipa: Fix use of null pointer in log macro
Fixes: Coverity CID#214962 Fixes: Coverity CID#214963 Change-Id: Iafea915dbbbfbaa710fb5899cb9be5e507ba384c
Diffstat (limited to 'src/osmo-bsc')
-rw-r--r--src/osmo-bsc/abis_nm.c3
-rw-r--r--src/osmo-bsc/bts_ipaccess_nanobts.c4
2 files changed, 2 insertions, 5 deletions
diff --git a/src/osmo-bsc/abis_nm.c b/src/osmo-bsc/abis_nm.c
index e2c328374..73dc2d018 100644
--- a/src/osmo-bsc/abis_nm.c
+++ b/src/osmo-bsc/abis_nm.c
@@ -55,9 +55,6 @@
#define OM_HEADROOM_SIZE 128
#define IPACC_SEGMENT_SIZE 245
-#define LOGPFOH(ss, lvl, foh, fmt, args ...) LOGP(ss, lvl, "%s: " fmt, abis_nm_dump_foh(foh), ## args)
-#define DEBUGPFOH(ss, foh, fmt, args ...) LOGPFOH(ss, LOGL_DEBUG, foh, fmt, ## args)
-
int abis_nm_tlv_parse(struct tlv_parsed *tp, struct gsm_bts *bts, const uint8_t *buf, int len)
{
if (!bts->model)
diff --git a/src/osmo-bsc/bts_ipaccess_nanobts.c b/src/osmo-bsc/bts_ipaccess_nanobts.c
index 134d50a79..577be13f7 100644
--- a/src/osmo-bsc/bts_ipaccess_nanobts.c
+++ b/src/osmo-bsc/bts_ipaccess_nanobts.c
@@ -380,7 +380,7 @@ static void nm_rx_set_radio_attr_ack(struct msgb *oml_msg)
struct gsm_bts_trx *trx = gsm_bts_trx_num(bts, foh->obj_inst.trx_nr);
if (!trx || foh->obj_class != NM_OC_RADIO_CARRIER) {
- LOG_TRX(trx, DNM, LOGL_ERROR, "Set Radio Carrier Attr Ack received on non Radio Carrier object!\n");
+ LOGPFOH(DNM, LOGL_ERROR, foh, "Set Radio Carrier Attr Ack received on non Radio Carrier object!\n");
return;
}
osmo_fsm_inst_dispatch(trx->mo.fi, NM_EV_SET_ATTR_ACK, NULL);
@@ -392,7 +392,7 @@ static void nm_rx_set_chan_attr_ack(struct msgb *oml_msg)
struct gsm_bts_trx_ts *ts = abis_nm_get_ts(oml_msg);
if (!ts || foh->obj_class != NM_OC_CHANNEL) {
- LOG_TS(ts, LOGL_ERROR, "Set Channel Attr Ack received on non Radio Channel object!\n");
+ LOGPFOH(DNM, LOGL_ERROR, foh, "Set Channel Attr Ack received on non Radio Channel object!\n");
return;
}
osmo_fsm_inst_dispatch(ts->mo.fi, NM_EV_SET_ATTR_ACK, NULL);