neels has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/libosmo-pfcp/+/32363 )


Change subject: coverity: fix null deref
......................................................................

coverity: fix null deref

fixup for
"pfcp_msg: refactor LOG_PFCP_MSG
e6ff99d7acbe270ed8f271daeaafc99e03a48176
Change-Id Ic84090c9b1a34185577cfb2ea1efa9c07542df34

Related: CID#313611
Change-Id: I347a813b31c839eae6b752982952367b2e664dc4
---
M src/libosmo-pfcp/pfcp_msg.c
1 file changed, 16 insertions(+), 1 deletion(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmo-pfcp refs/changes/63/32363/1

diff --git a/src/libosmo-pfcp/pfcp_msg.c b/src/libosmo-pfcp/pfcp_msg.c
index 74335fe..abcee18 100644
--- a/src/libosmo-pfcp/pfcp_msg.c
+++ b/src/libosmo-pfcp/pfcp_msg.c
@@ -555,7 +555,7 @@
 {
        struct osmo_strbuf sb = { .buf = buf, .len = buflen };
        struct osmo_fsm_inst *fi = m ? (m->ctx.session_fi ?: m->ctx.peer_fi) : 
NULL;
-       enum osmo_pfcp_cause *cause = osmo_pfcp_msg_cause(m);
+       enum osmo_pfcp_cause *cause = m ? osmo_pfcp_msg_cause(m) : NULL;

        if (fi)
                OSMO_STRBUF_PRINTF(sb, "%s{%s}: ",

--
To view, visit https://gerrit.osmocom.org/c/libosmo-pfcp/+/32363
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmo-pfcp
Gerrit-Branch: master
Gerrit-Change-Id: I347a813b31c839eae6b752982952367b2e664dc4
Gerrit-Change-Number: 32363
Gerrit-PatchSet: 1
Gerrit-Owner: neels <[email protected]>
Gerrit-MessageType: newchange

Reply via email to