fixup null pointer deref
This commit is contained in:
parent
387edd67ac
commit
d251b5379c
|
@ -928,6 +928,11 @@ int msc_mgcp_ass_complete(struct gsm_subscriber_connection *conn, uint16_t port,
|
|||
{
|
||||
struct mgcp_ctx *mgcp_ctx;
|
||||
|
||||
if (!conn) {
|
||||
LOGP(DMGCP, LOGL_ERROR, "invalid conn, assignment completion failed\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
if (port == 0) {
|
||||
LOGP(DMGCP, LOGL_ERROR, "(subscriber:%s) invalid remote call leg port, call completion failed\n",
|
||||
vlr_subscr_name(conn->vsub));
|
||||
|
@ -938,11 +943,6 @@ int msc_mgcp_ass_complete(struct gsm_subscriber_connection *conn, uint16_t port,
|
|||
vlr_subscr_name(conn->vsub));
|
||||
return -EINVAL;
|
||||
}
|
||||
if (!conn) {
|
||||
LOGP(DMGCP, LOGL_ERROR, "(subscriber:%s) invalid conn, assignment completion failed\n",
|
||||
vlr_subscr_name(conn->vsub));
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
mgcp_ctx = conn->rtp.mgcp_ctx;
|
||||
if (!mgcp_ctx) {
|
||||
|
|
Loading…
Reference in New Issue