mncc: Extract the RTP port information before continuing

These need to be used by the SIP leg to move forward.
This commit is contained in:
Holger Hans Peter Freyther 2016-03-24 17:35:42 +01:00
parent 153ebbf6e2
commit 292e2cddd0
2 changed files with 17 additions and 1 deletions

View File

@ -34,6 +34,14 @@ struct call_leg {
int type;
struct call *call;
/**
* RTP data
*/
uint32_t ip;
uint16_t port;
uint32_t payload_type;
uint32_t payload_msg_type;
/**
* Set by the call_leg implementation and will be called
* by the application to release the call.

View File

@ -192,9 +192,17 @@ static void check_rtp_create(struct mncc_connection *conn, char *buf, int rc)
return mncc_send(conn, MNCC_REJ_REQ, rtp->callref);
}
/* extract information about where the RTP is */
leg->base.ip = rtp->ip;
leg->base.port = rtp->port;
leg->base.payload_type = rtp->payload_type;
leg->base.payload_msg_type = rtp->payload_msg_type;
/* TODO.. now we can continue with the call */
LOGP(DMNCC, LOGL_DEBUG,
"RTP set-up continuing with call with leg(%u)\n", leg->callref);
"RTP cnt leg(%u) ip(%u), port(%u) pt(%u) ptm(%u)\n",
leg->callref, leg->base.ip, leg->base.port,
leg->base.payload_type, leg->base.payload_msg_type);
stop_cmd_timer(leg, MNCC_RTP_CREATE);
continue_call(leg);
}