annotate sip-manual-out/rtp.c @ 188:6aecee01cf0a

sip-manual-out: add RTP stream continuity analysis
author Mychaela Falconia <falcon@freecalypso.org>
date Fri, 17 Mar 2023 01:14:57 -0800
parents 258932879f8b
children 1266e024de6c
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
187
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
1 /*
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
2 * In this module we implement our RTP handling: obtaining a PSTN-side
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
3 * RTP endpoint from themwi-rtp-mgr, then handling read select on RTP
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
4 * and RTCP UDP sockets.
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
5 */
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
6
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
7 #include <sys/types.h>
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
8 #include <sys/socket.h>
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
9 #include <netinet/in.h>
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
10 #include <stdio.h>
188
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
11 #include <stdint.h>
187
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
12 #include <stdlib.h>
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
13 #include <string.h>
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
14 #include <strings.h>
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
15 #include "../include/tmgw_const.h"
188
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
16 #include "../include/rtp_defs.h"
187
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
17 #include "../librtpalloc/rtp_alloc_simple.h"
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
18
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
19 struct sockaddr_in rtp_local_addr;
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
20 int rtp_udp_fd, rtcp_udp_fd;
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
21
188
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
22 static int rtp_start_flag, rtp_bad_flag, rtp_ssrc_chg_flag;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
23 static int rtp_seq_brk_flag, rtp_seq_zero_flag, rtp_seq_neg_flag;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
24 static int rtp_ts_brk_flag;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
25 static uint32_t rtp_ssrc;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
26 static uint32_t rtp_last_ts;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
27 static uint16_t rtp_last_seq;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
28 static int got_some_rtcp;
187
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
29
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
30 void
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
31 obtain_rtp_endp()
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
32 {
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
33 int rc;
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
34 struct rtp_alloc_simple res;
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
35
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
36 rc = rtp_alloc_simple(TMGW_EP_TYPE_PSTN_ONLY, &res);
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
37 if (rc < 0)
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
38 exit(1); /* error msg already printed */
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
39 bcopy(&res.pstn_addr, &rtp_local_addr, sizeof(struct sockaddr_in));
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
40 rtp_udp_fd = res.pstn_rtp_fd;
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
41 rtcp_udp_fd = res.pstn_rtcp_fd;
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
42 }
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
43
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
44 void
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
45 rtp_rx_select()
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
46 {
188
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
47 struct rtp_packet pkt;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
48 struct sockaddr_in sin_from;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
49 socklen_t addrlen;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
50 int16_t seq_delta;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
51 int32_t ts_delta;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
52 int rc;
187
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
53
188
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
54 addrlen = sizeof(struct sockaddr_in);
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
55 rc = recvfrom(rtp_udp_fd, &pkt, sizeof pkt, 0,
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
56 (struct sockaddr *) &sin_from, &addrlen);
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
57 if (rc < 0)
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
58 return;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
59 if (rc != RTP_PACKET_SIZE_PSTN) {
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
60 bad_rtp_pkt: if (!rtp_bad_flag) {
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
61 printf("Got a bad RTP packet\n");
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
62 rtp_bad_flag = 1;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
63 }
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
64 return;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
65 }
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
66 if (pkt.v_p_x_cc != 0x80)
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
67 goto bad_rtp_pkt;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
68 switch (pkt.m_pt & 0x7F) {
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
69 case PSTN_CODEC_PCMU:
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
70 case PSTN_CODEC_PCMA:
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
71 break;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
72 default:
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
73 goto bad_rtp_pkt;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
74 }
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
75 if (rtp_start_flag && pkt.ssrc != rtp_ssrc) {
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
76 if (!rtp_ssrc_chg_flag) {
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
77 printf("Rx RTP stream changed SSRC\n");
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
78 rtp_ssrc_chg_flag = 1;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
79 }
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
80 } else if (rtp_start_flag) {
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
81 seq_delta = ntohs(pkt.seq) - rtp_last_seq;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
82 ts_delta = ntohl(pkt.tstamp) - rtp_last_ts;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
83 if (seq_delta == 0) {
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
84 if (!rtp_seq_zero_flag) {
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
85 printf("Rx RTP seq zero increment\n");
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
86 rtp_seq_zero_flag = 1;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
87 }
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
88 return;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
89 }
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
90 if (seq_delta < 0) {
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
91 if (!rtp_seq_neg_flag) {
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
92 printf("Rx RTP seq negative increment\n");
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
93 rtp_seq_neg_flag = 1;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
94 }
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
95 return;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
96 }
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
97 if (seq_delta != 1) {
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
98 if (!rtp_seq_brk_flag) {
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
99 printf("Rx RTP stream seq break\n");
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
100 rtp_seq_brk_flag = 1;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
101 }
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
102 } else if (ts_delta != 160) {
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
103 if (!rtp_ts_brk_flag) {
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
104 printf("Rx RTP stream tstamp break\n");
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
105 rtp_ts_brk_flag = 1;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
106 }
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
107 }
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
108 }
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
109 rtp_ssrc = pkt.ssrc;
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
110 rtp_last_ts = ntohl(pkt.tstamp);
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
111 rtp_last_seq = ntohs(pkt.seq);
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
112 if (!rtp_start_flag) {
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
113 printf("Rx RTP stream begins with seq=%u ts=%u\n",
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
114 rtp_last_seq, rtp_last_ts);
6aecee01cf0a sip-manual-out: add RTP stream continuity analysis
Mychaela Falconia <falcon@freecalypso.org>
parents: 187
diff changeset
115 rtp_start_flag = 1;
187
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
116 }
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
117 }
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
118
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
119 void
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
120 rtcp_rx_select()
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
121 {
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
122 u_char buf[512];
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
123
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
124 recv(rtcp_udp_fd, buf, sizeof buf, 0);
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
125 if (!got_some_rtcp) {
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
126 printf("Got some RTCP\n");
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
127 got_some_rtcp = 1;
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
128 }
258932879f8b sip-manual-out: rework for internal RTP handling, using themwi-rtp-mgr
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
129 }