summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorthe 34c3 gsm team <34c3-gsm@congress>2017-12-28 00:27:34 +0100
committerthe 34c3 gsm team <34c3-gsm@congress>2017-12-28 00:40:01 +0100
commitce53b71f45be20b16f17d8644f47133127e7f794 (patch)
tree9c35cb5a832954cb23b7aeb51fc9a37ba2298f0d
parent3272a0da582ea1f4ecf6d07190a7a2f2648afc46 (diff)
add inet_ntoa to the log when receiving the RTP_CREAT
-rw-r--r--src/mncc.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/mncc.c b/src/mncc.c
index fe16683..2b5f614 100644
--- a/src/mncc.c
+++ b/src/mncc.c
@@ -430,6 +430,7 @@ static void check_rtp_create(struct mncc_connection *conn, char *buf, int rc)
{
struct gsm_mncc_rtp *rtp;
struct mncc_call_leg *leg;
+ struct in_addr net = { 0 };
if (rc < sizeof(*rtp)) {
LOGP(DMNCC, LOGL_ERROR, "gsm_mncc_rtp of wrong size %d < %zu\n",
@@ -449,11 +450,12 @@ static void check_rtp_create(struct mncc_connection *conn, char *buf, int rc)
leg->base.port = rtp->port;
leg->base.payload_type = rtp->payload_type;
leg->base.payload_msg_type = rtp->payload_msg_type;
+ net.s_addr = ntohl(rtp->ip);
/* TODO.. now we can continue with the call */
LOGP(DMNCC, LOGL_DEBUG,
- "RTP cnt leg(%u) ip(%u), port(%u) pt(%u) ptm(%u)\n",
- leg->callref, leg->base.ip, leg->base.port,
+ "RTP cnt leg(%u) ip(%u/%s), port(%u) pt(%u) ptm(%u)\n",
+ leg->callref, leg->base.ip, inet_ntoa(net), leg->base.port,
leg->base.payload_type, leg->base.payload_msg_type);
stop_cmd_timer(leg, MNCC_RTP_CREATE);
continue_call(leg);