[libpri-commits] rmudgett: branch 1.4 r2098 - /branches/1.4/q921.c

SVN commits to the libpri project libpri-commits at lists.digium.com
Fri Nov 5 14:02:45 CDT 2010


Author: rmudgett
Date: Fri Nov  5 14:02:42 2010
New Revision: 2098

URL: http://svnview.digium.com/svn/libpri?view=rev&rev=2098
Log:
Mainly put space after switch and while keywords.

Modified:
    branches/1.4/q921.c

Modified: branches/1.4/q921.c
URL: http://svnview.digium.com/svn/libpri/branches/1.4/q921.c?view=diff&rev=2098&r1=2097&r2=2098
==============================================================================
--- branches/1.4/q921.c (original)
+++ branches/1.4/q921.c Fri Nov  5 14:02:42 2010
@@ -51,7 +51,7 @@
 	(hf).h.ea1 = 0; \
 	(hf).h.ea2 = 1; \
 	(hf).h.tei = (link)->tei; \
-} while(0)
+} while (0)
 
 static void q921_dump_pri(struct q921_link *link, char direction_tag);
 static void q921_establish_data_link(struct q921_link *link);
@@ -253,7 +253,7 @@
 	h.u.m2 = 3;	/* M2 = 3 */
 	h.u.p_f = fbit;	/* Final set appropriately */
 	h.u.ft = Q921_FRAMETYPE_U;
-	switch(ctrl->localtype) {
+	switch (ctrl->localtype) {
 	case PRI_NETWORK:
 		h.h.c_r = 0;
 		break;
@@ -282,7 +282,7 @@
 	h.u.m2 = 0;	/* M2 = 0 */
 	h.u.p_f = pbit;	/* Poll set appropriately */
 	h.u.ft = Q921_FRAMETYPE_U;
-	switch(ctrl->localtype) {
+	switch (ctrl->localtype) {
 	case PRI_NETWORK:
 		h.h.c_r = 0;
 		break;
@@ -311,7 +311,7 @@
 	h.u.m2 = 0;		/* M2 = 0 */
 	h.u.p_f = fbit;	/* Final set appropriately */
 	h.u.ft = Q921_FRAMETYPE_U;
-	switch(ctrl->localtype) {
+	switch (ctrl->localtype) {
 	case PRI_NETWORK:
 		h.h.c_r = 0;
 		break;
@@ -340,7 +340,7 @@
 	h.u.m2 = 3;	/* M2 = 3 */
 	h.u.p_f = 1;	/* Poll bit set */
 	h.u.ft = Q921_FRAMETYPE_U;
-	switch(ctrl->localtype) {
+	switch (ctrl->localtype) {
 	case PRI_NETWORK:
 		h.h.c_r = 1;
 		break;
@@ -430,7 +430,7 @@
 	struct q921_frame *f = link->tx_queue;
 	int cnt = 0;
 
-	while(f) {
+	while (f) {
 		if (f->transmitted)
 			cnt++;
 		f = f->next;
@@ -604,7 +604,7 @@
 	h.s.ft = 1;	/* Frametype (01) */
 	h.s.n_r = link->v_r;	/* Where to start retransmission N(R) */
 	h.s.p_f = pf;	
-	switch(ctrl->localtype) {
+	switch (ctrl->localtype) {
 	case PRI_NETWORK:
 		h.h.c_r = 0;
 		break;
@@ -634,7 +634,7 @@
 	h.s.ft = 1;	/* Frametype (01) */
 	h.s.n_r = link->v_r;	/* N(R) */
 	h.s.p_f = pbit;		/* Poll/Final set appropriately */
-	switch(ctrl->localtype) {
+	switch (ctrl->localtype) {
 	case PRI_NETWORK:
 		if (cmd)
 			h.h.c_r = 1;
@@ -768,7 +768,7 @@
 	h->u.p_f = 0;	/* Poll bit set */
 	h->u.ft = Q921_FRAMETYPE_U;
 
-	switch(ctrl->localtype) {
+	switch (ctrl->localtype) {
 	case PRI_NETWORK:
 		h->h.c_r = 1;
 		break;
@@ -1092,7 +1092,7 @@
 			direction_tag,
 			len - 3);
 		break;
-	};
+	}
 
 	if ((h->u.ft == 3) && (h->u.m3 == 0) && (h->u.m2 == 0) && (h->u.data[0] == 0x0f)) {
 		int ri;
@@ -1201,7 +1201,7 @@
 	ri = (h->data[1] << 8) | h->data[2];
 	tei = (h->data[4] >> 1);
 
-	switch(h->data[3]) {
+	switch (h->data[3]) {
 	case Q921_TEI_IDENTITY_REQUEST:
 		if (!BRI_NT_PTMP(ctrl)) {
 			return NULL;
@@ -1242,8 +1242,9 @@
 		q921_send_tei(ctrl, Q921_TEI_IDENTITY_ASSIGNED, ri, tei, 1);
 		break;
 	case Q921_TEI_IDENTITY_ASSIGNED:
-		if (!BRI_TE_PTMP(ctrl))
+		if (!BRI_TE_PTMP(ctrl)) {
 			return NULL;
+		}
 
 		/* Assuming we're operating on the specific TEI link here */
 		link = ctrl->link.next;
@@ -1290,8 +1291,9 @@
 		}
 		break;
 	case Q921_TEI_IDENTITY_CHECK_REQUEST:
-		if (!BRI_TE_PTMP(ctrl))
+		if (!BRI_TE_PTMP(ctrl)) {
 			return NULL;
+		}
 
 		/* Assuming we're operating on the specific TEI link here */
 		link = ctrl->link.next;
@@ -1307,8 +1309,9 @@
 		}
 		break;
 	case Q921_TEI_IDENTITY_REMOVE:
-		if (!BRI_TE_PTMP(ctrl))
+		if (!BRI_TE_PTMP(ctrl)) {
 			return NULL;
+		}
 
 		/* Assuming we're operating on the specific TEI link here */
 		link = ctrl->link.next;
@@ -2474,7 +2477,7 @@
 
 	ctrl = link->ctrl;
 
-	switch(h->h.data[0] & Q921_FRAMETYPE_MASK) {
+	switch (h->h.data[0] & Q921_FRAMETYPE_MASK) {
 	case 0:
 	case 2:
 		ev = q921_iframe_rx(link, h, len);




More information about the libpri-commits mailing list