aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPablo Neira Ayuso <pablo@netfilter.org>2012-02-23 19:18:59 +0100
committerPablo Neira Ayuso <pablo@netfilter.org>2012-02-23 19:25:00 +0100
commitb7672dd3855460a126e15c0c3d546d1e3808eb7f (patch)
tree1ef65fb43bbca3f87350751c2aed34d438c38f94
parente2d1c87d6cfd0557861673513c58f6796f8cf709 (diff)
examples: Display more details on RTP payload in rtp-udp-test-*0.0.1
Minor change, more verbose output to make sure the functions in the library are doing OK. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
-rw-r--r--examples/rtp-udp-test-client.c6
-rw-r--r--examples/rtp-udp-test-server.c6
2 files changed, 6 insertions, 6 deletions
diff --git a/examples/rtp-udp-test-client.c b/examples/rtp-udp-test-client.c
index 4989a6c..3723b6b 100644
--- a/examples/rtp-udp-test-client.c
+++ b/examples/rtp-udp-test-client.c
@@ -60,8 +60,8 @@ static int read_cb(struct osmo_dgram_conn *conn)
return -1;
}
- LOGP(DLINP, LOGL_DEBUG, "received message with RTP payload type: %d\n",
- payload_type);
+ LOGP(DLINP, LOGL_DEBUG, "received message with payload type: %d "
+ "and size: %d (%s)\n", payload_type, msg->len, msg->data);
msgb_free(msg);
return 0;
@@ -81,7 +81,7 @@ static void *tall_test;
int main(int argc, char *argv[])
{
int i;
- char dummy_data[RTP_PT_GSM_FULL_PAYLOAD_LEN] = {};
+ char dummy_data[RTP_PT_GSM_FULL_PAYLOAD_LEN] = "payload test";
signal(SIGINT, sighandler);
diff --git a/examples/rtp-udp-test-server.c b/examples/rtp-udp-test-server.c
index f1920b8..2f6c72f 100644
--- a/examples/rtp-udp-test-server.c
+++ b/examples/rtp-udp-test-server.c
@@ -37,7 +37,7 @@ static struct osmo_rtp_handle *rtp;
int read_cb(struct osmo_dgram_conn *conn)
{
struct msgb *msg;
- char dummy_data[RTP_PT_GSM_FULL_PAYLOAD_LEN] = {};
+ char dummy_data[RTP_PT_GSM_FULL_PAYLOAD_LEN] = "payload test";
int payload_type;
LOGP(DRTP_TEST, LOGL_DEBUG, "received message from datagram\n");
@@ -57,8 +57,8 @@ int read_cb(struct osmo_dgram_conn *conn)
LOGP(DRTP_TEST, LOGL_ERROR, "cannot parse RTP message\n");
return -1;
}
- LOGP(DLINP, LOGL_DEBUG, "received message with payload type: %d\n",
- payload_type);
+ LOGP(DLINP, LOGL_DEBUG, "received message with RTP payload type: %d "
+ "and size: %d (%s)\n", payload_type, msg->len, msg->data);
/*
* ... now build gsm_data_frame, set callref and msg_type based