aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Eversberg <jolly@eversberg.eu>2023-07-19 09:46:18 +0200
committerlaforge <laforge@osmocom.org>2023-07-21 11:16:16 +0000
commitd63776051ebd5962f5e4e651ec282195956eb22e (patch)
treef5f2900021087ca9b05b36ae0a5be0c33e675506
parent7e65ed9091b8a1565435364c571a8f7949805e49 (diff)
ASCI: Fix wrong check for Null pointer in vgcs_cell_fsm_null()
Fixes: CID#322145, CID#322141 Change-Id: Iec0820f612450cde772076131b07fe7819d35790
-rw-r--r--src/libmsc/msc_vgcs.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libmsc/msc_vgcs.c b/src/libmsc/msc_vgcs.c
index 7f72583fc..c6f5e1653 100644
--- a/src/libmsc/msc_vgcs.c
+++ b/src/libmsc/msc_vgcs.c
@@ -2351,12 +2351,12 @@ static void vgcs_cell_fsm_null(struct osmo_fsm_inst *fi, uint32_t event, void *d
/* Set initial mode. */
rtp_stream_set_mode(cell->rtps, MGCP_CONN_RECV_ONLY);
/* Commit RTP stream. */
- if (!cell->bss && !cell->bss->trans) {
- LOG_CELL(cell, LOGL_DEBUG, "No transaction, cannot continue.\n");
+ if (!cell->bss || !cell->bss->trans) {
+ LOG_CELL(cell, LOGL_DEBUG, "No BSS/transaction, cannot continue.\n");
cell_clear(cell, GSM0808_CAUSE_PROTOCOL_ERROR_BETWEEN_BSS_AND_MSC);
break;
}
- if (!cell->mgw && !cell->mgw->mgw_ep) {
+ if (!cell->mgw || !cell->mgw->mgw_ep) {
LOG_CELL(cell, LOGL_DEBUG, "No MGW endpoint, cannot continue.\n");
cell_clear(cell, GSM0808_CAUSE_PROTOCOL_ERROR_BETWEEN_BSS_AND_MSC);
break;