[Asterisk-code-review] res rtp asterisk: Remove some unused structure fields. (asterisk[16])
George Joseph
asteriskteam at digium.com
Tue Dec 18 10:42:09 CST 2018
George Joseph has submitted this change and it was merged. ( https://gerrit.asterisk.org/10816 )
Change subject: res_rtp_asterisk: Remove some unused structure fields.
......................................................................
res_rtp_asterisk: Remove some unused structure fields.
All of the fields that were removed were no longer referenced except for
'lastrxts' and 'rxseqno' which were only ever written to.
Change-Id: I5a5d31eb33e97663843698f58d0d97f22a76627c
---
M res/res_rtp_asterisk.c
1 file changed, 0 insertions(+), 18 deletions(-)
Approvals:
Joshua C. Colp: Looks good to me, but someone else must approve
Benjamin Keith Ford: Looks good to me, but someone else must approve
Corey Farrell: Looks good to me, but someone else must approve
George Joseph: Looks good to me, approved; Approved for Submit
diff --git a/res/res_rtp_asterisk.c b/res/res_rtp_asterisk.c
index 1901c10..a13725a 100644
--- a/res/res_rtp_asterisk.c
+++ b/res/res_rtp_asterisk.c
@@ -323,12 +323,10 @@
unsigned int themssrc; /*!< Their SSRC */
unsigned int themssrc_valid; /*!< True if their SSRC is available. */
unsigned int lastts;
- unsigned int lastrxts;
unsigned int lastividtimestamp;
unsigned int lastovidtimestamp;
unsigned int lastitexttimestamp;
unsigned int lastotexttimestamp;
- unsigned int lasteventseqn;
int lastrxseqno; /*!< Last received sequence number, from the network */
int expectedrxseqno; /*!< Next expected sequence number, from the network */
AST_VECTOR(, int) missing_seqno; /*!< A vector of sequence numbers we never received */
@@ -345,10 +343,6 @@
struct ast_format *lasttxformat;
struct ast_format *lastrxformat;
- int rtptimeout; /*!< RTP timeout time (negative or zero means disabled, negative value means temporarily disabled) */
- int rtpholdtimeout; /*!< RTP timeout when on hold (negative or zero means disabled, negative value means temporarily disabled). */
- int rtpkeepalive; /*!< Send RTP comfort noice packets for keepalive */
-
/* DTMF Reception Variables */
char resp; /*!< The current digit being processed */
unsigned int last_seqno; /*!< The last known sequence number for any DTMF packet */
@@ -367,17 +361,11 @@
struct timeval rxcore;
struct timeval txcore;
double drxcore; /*!< The double representation of the first received packet */
- struct timeval lastrx; /*!< timeval when we last received a packet */
struct timeval dtmfmute;
struct ast_smoother *smoother;
- int *ioid;
unsigned short seqno; /*!< Sequence number, RFC 3550, page 13. */
- unsigned short rxseqno;
struct ast_sched_context *sched;
- struct io_context *io;
- void *data;
struct ast_rtcp *rtcp;
- struct ast_rtp *bridged; /*!< Who we are Packet bridged to */
unsigned int asymmetric_codec; /*!< Indicate if asymmetric send/receive codecs are allowed */
struct ast_rtp_instance *bundled; /*!< The RTP instance we are bundled to */
@@ -6456,7 +6444,6 @@
ast_codec_media_type2str(ast_format_get_type(rtp->f.subclass.format)));
return &ast_null_frame;
}
- rtp->rxseqno = seqno;
if (rtp->dtmf_timeout && rtp->dtmf_timeout < timestamp) {
rtp->dtmf_timeout = 0;
@@ -6472,8 +6459,6 @@
}
}
- rtp->lastrxts = timestamp;
-
rtp->f.src = "RTP";
rtp->f.mallocd = 0;
rtp->f.datalen = res - hdrlen;
@@ -6863,7 +6848,6 @@
ast_sockaddr_copy(&rtp->rtcp->them, &addr);
ast_sockaddr_set_port(&rtp->rtcp->them, ast_sockaddr_port(&addr) + 1);
}
- rtp->rxseqno = 0;
ast_set_flag(rtp, FLAG_NAT_ACTIVE);
if (rtpdebug)
ast_debug(0, "RTP NAT: Got audio from other end. Now sending to address %s\n",
@@ -7385,8 +7369,6 @@
ast_rtp_instance_set_remote_address(mapping->instance, addr);
}
- rtp->rxseqno = 0;
-
if (strictrtp && rtp->strict_rtp_state != STRICT_RTP_OPEN
&& !ast_sockaddr_isnull(addr) && ast_sockaddr_cmp(addr, &rtp->strict_rtp_address)) {
/* We only need to learn a new strict source address if we've been told the source is
--
To view, visit https://gerrit.asterisk.org/10816
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings
Gerrit-Project: asterisk
Gerrit-Branch: 16
Gerrit-MessageType: merged
Gerrit-Change-Id: I5a5d31eb33e97663843698f58d0d97f22a76627c
Gerrit-Change-Number: 10816
Gerrit-PatchSet: 1
Gerrit-Owner: Sean Bright <sean.bright at gmail.com>
Gerrit-Reviewer: Benjamin Keith Ford <bford at digium.com>
Gerrit-Reviewer: Corey Farrell <git at cfware.com>
Gerrit-Reviewer: Friendly Automation (1000185)
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Joshua C. Colp <jcolp at digium.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20181218/5d91fe78/attachment-0001.html>
More information about the asterisk-code-review
mailing list