[svn-commits] rmudgett: branch 1.4 r1845 - /branches/1.4/q921.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Tue Aug 3 12:34:00 CDT 2010


Author: rmudgett
Date: Tue Aug  3 12:33:54 2010
New Revision: 1845

URL: http://svnview.digium.com/svn/libpri?view=rev&rev=1845
Log:
Q921_TIMER_RECOVERY SDL issue in q921_rnr_rx()

Added missing code specified by Q.921 (Figure B.8 Page 85) when receive
RNR in "Timer Recovery" state.

(closes issue #16791)
Reported by: alecdavis
Patches:
      rnr_timer_recovery.diff.txt uploaded by alecdavis (license 585)

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=1845&r1=1844&r2=1845
==============================================================================
--- branches/1.4/q921.c (original)
+++ branches/1.4/q921.c Tue Aug  3 12:33:54 2010
@@ -1781,6 +1781,7 @@
 		}
 		break;
 	case Q921_TIMER_RECOVERY:
+		/* Q.921 Figure B.8 Q921 (Sheet 6 of 9) Page 85 */
 		ctrl->peer_rx_busy = 1;
 		if (is_command(ctrl, h)) {
 			if (h->s.p_f) {
@@ -1793,6 +1794,15 @@
 					q921_setstate(ctrl, Q921_AWAITING_ESTABLISHMENT);
 					break;
 				}
+			} else {
+				if (n_r_is_valid(ctrl, h->s.n_r)) {
+					update_v_a(ctrl, h->s.n_r);
+					break;
+				} else {
+					n_r_error_recovery(ctrl);
+					q921_setstate(ctrl, Q921_AWAITING_ESTABLISHMENT);
+					break;
+				}
 			}
 		} else {
 			if (h->s.p_f) {
@@ -1801,6 +1811,15 @@
 					restart_t200(ctrl);
 					q921_invoke_retransmission(ctrl, h->s.n_r);
 					q921_setstate(ctrl, Q921_MULTI_FRAME_ESTABLISHED);
+					break;
+				} else {
+					n_r_error_recovery(ctrl);
+					q921_setstate(ctrl, Q921_AWAITING_ESTABLISHMENT);
+					break;
+				}
+			} else {
+				if (n_r_is_valid(ctrl, h->s.n_r)) {
+					update_v_a(ctrl, h->s.n_r);
 					break;
 				} else {
 					n_r_error_recovery(ctrl);




More information about the svn-commits mailing list