[svn-commits] trunk r31870 - /trunk/channels/chan_sip.c

svn-commits at lists.digium.com svn-commits at lists.digium.com
Sat Jun 3 16:34:01 MST 2006


Author: rizzo
Date: Sat Jun  3 18:34:01 2006
New Revision: 31870

URL: http://svn.digium.com/view/asterisk?rev=31870&view=rev
Log:
mark XXX some places where there is a return right before
a large "else" block, which is suitable for a reduction of
the nesting depth.


Modified:
    trunk/channels/chan_sip.c

Modified: trunk/channels/chan_sip.c
URL: http://svn.digium.com/view/asterisk/trunk/channels/chan_sip.c?rev=31870&r1=31869&r2=31870&view=diff
==============================================================================
--- trunk/channels/chan_sip.c (original)
+++ trunk/channels/chan_sip.c Sat Jun  3 18:34:01 2006
@@ -6750,6 +6750,9 @@
 		sip_scheddestroy(p, SIP_TRANS_TIMEOUT);
 		return AUTH_CHALLENGE_SENT;
 	} else {	/* We have auth, so check it */
+
+		/* XXX reduce nesting here */
+
 		/* Whoever came up with the authentication section of SIP can suck my %&#$&* for not putting
 	   	an example in the spec of just what it is you're doing a hash on. */
 		char a1_hash[256];
@@ -12602,6 +12605,8 @@
 		ast_set_flag(&p->flags[0], SIP_NEEDDESTROY);	
 		return 0;
 	} else {
+		/* XXX reduce nesting here */
+
 		/* Initialize tag for new subscriptions */	
 		if (ast_strlen_zero(p->tag))
 			make_our_tag(p->tag, sizeof(p->tag));
@@ -12700,6 +12705,7 @@
 				ast_set_flag(&p->flags[0], SIP_NEEDDESTROY);	
 				return 0;
 			} else {
+				/* XXX reduce nesting here */
 				struct sip_pvt *p_old;
 	
 				transmit_response(p, "200 OK", req);



More information about the svn-commits mailing list