[asterisk-commits] mmichelson: branch 10 r366412 - in /branches/10: ./ pbx/dundi-parser.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon May 14 15:07:04 CDT 2012


Author: mmichelson
Date: Mon May 14 15:06:58 2012
New Revision: 366412

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=366412
Log:
Fix two more coverity constant expression result findings.

These correspond to findings 0 and 1 in the core findings of
ASTERISK-19649.

After contacting Mark Spencer, he was unsure of what the intent
behind these lines of code were, so they are being axed.

For Asterisk 1.8 and 10, the output of debugging DUNDi frames
will not be changed, but for trunk the "Retry" portion will
be omitted since it does not properly distinguish retransmissions
from initial frames.

(closes issue ASTERISK-19649)
Reported by Matthew Jordan
........

Merged revisions 366409 from http://svn.asterisk.org/svn/asterisk/branches/1.8

Modified:
    branches/10/   (props changed)
    branches/10/pbx/dundi-parser.c

Propchange: branches/10/
------------------------------------------------------------------------------
Binary property 'branch-1.8-merged' - no diff available.

Modified: branches/10/pbx/dundi-parser.c
URL: http://svnview.digium.com/svn/asterisk/branches/10/pbx/dundi-parser.c?view=diff&rev=366412&r1=366411&r2=366412
==============================================================================
--- branches/10/pbx/dundi-parser.c (original)
+++ branches/10/pbx/dundi-parser.c Mon May 14 15:06:58 2012
@@ -454,15 +454,7 @@
 	char subclass2[20];
 	char *subclass;
 	char tmp[256];
-	char retries[20];
-	if (ntohs(fhi->dtrans) & DUNDI_FLAG_RETRANS)
-		strcpy(retries, "Yes");
-	else
-		strcpy(retries, "No");
-	if ((ntohs(fhi->strans) & DUNDI_FLAG_RESERVED)) {
-		/* Ignore frames with high bit set to 1 */
-		return;
-	}
+	const char *retries = "Yes";
 	if ((fhi->cmdresp & 0x3f) > (int)sizeof(commands)/(int)sizeof(char *)) {
 		snprintf(class2, (int)sizeof(class2), "(%d?)", fhi->cmdresp);
 		class = class2;




More information about the asterisk-commits mailing list