[Asterisk-code-review] res_rtp_asterisk: Protect access to nochecksums with #ifdef (asterisk[16])

Joshua Colp asteriskteam at digium.com
Tue Apr 28 13:37:58 CDT 2020


Joshua Colp has submitted this change. ( https://gerrit.asterisk.org/c/asterisk/+/14312 )

Change subject: res_rtp_asterisk: Protect access to nochecksums with #ifdef
......................................................................

res_rtp_asterisk: Protect access to nochecksums with #ifdef

Recently code accessing nochecksums variable has been added without including #ifdef SO_NO_CHECK protection, while the variable is created only when such constant is defined.

ASTERISK-28852 #close

Change-Id: I381718893b80599ab8635f2b594a10c1000d595e
---
M res/res_rtp_asterisk.c
1 file changed, 2 insertions(+), 0 deletions(-)

Approvals:
  Benjamin Keith Ford: Looks good to me, approved
  George Joseph: Looks good to me, but someone else must approve
  Joshua Colp: Approved for Submit



diff --git a/res/res_rtp_asterisk.c b/res/res_rtp_asterisk.c
index 75be561..3bcfada 100644
--- a/res/res_rtp_asterisk.c
+++ b/res/res_rtp_asterisk.c
@@ -8868,7 +8868,9 @@
 	ast_cli(a->fd, "----------------\n");
 	ast_cli(a->fd, "  Port start:      %d\n", rtpstart);
 	ast_cli(a->fd, "  Port end:        %d\n", rtpend);
+#ifdef SO_NO_CHECK
 	ast_cli(a->fd, "  Checksums:       %s\n", AST_CLI_YESNO(nochecksums == 0));
+#endif
 	ast_cli(a->fd, "  DTMF Timeout:    %d\n", dtmftimeout);
 	ast_cli(a->fd, "  Strict RTP:      %s\n", AST_CLI_YESNO(strictrtp));
 

-- 
To view, visit https://gerrit.asterisk.org/c/asterisk/+/14312
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: 16
Gerrit-Change-Id: I381718893b80599ab8635f2b594a10c1000d595e
Gerrit-Change-Number: 14312
Gerrit-PatchSet: 2
Gerrit-Owner: Guido Falsi <madpilot at freebsd.org>
Gerrit-Reviewer: Benjamin Keith Ford <bford at digium.com>
Gerrit-Reviewer: Friendly Automation
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Joshua Colp <jcolp at sangoma.com>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20200428/dd7f312c/attachment-0001.html>


More information about the asterisk-code-review mailing list