Revision: 15592
Author: baranowb
Date: Wed Dec  1 06:29:20 2010
Log: [SS7] Small fixes to MTP2 - remove unused code, ident and small optimization to set state op.
http://code.google.com/p/mobicents/source/detail?r=15592

Modified:
/trunk/protocols/ss7/mtp/mtp-impl/src/main/java/org/mobicents/protocols/ss7/mtp/Mtp2.java

=======================================
--- /trunk/protocols/ss7/mtp/mtp-impl/src/main/java/org/mobicents/protocols/ss7/mtp/Mtp2.java Wed Dec 1 04:46:12 2010 +++ /trunk/protocols/ss7/mtp/mtp-impl/src/main/java/org/mobicents/protocols/ss7/mtp/Mtp2.java Wed Dec 1 06:29:20 2010
@@ -201,7 +201,8 @@
     private TxQueue txQueue = new TxQueue();
     private int doCRC = 0;
     private int rxCRC = 0xffff;
-    private int txCRC = 0xffff;    // //////////////////////
+    private int txCRC = 0xffff;
+    // //////////////////////
     // SEQUENCING AND RTR //
     // //////////////////////
     /**
@@ -402,6 +403,11 @@

     private void setState(int newState)
     {
+       if(this.state == newState)
+       {
+               return;
+       }
+
        if(logger.isInfoEnabled())
        {
                //iirc it should be info
@@ -545,12 +551,7 @@
                     } else {
                         queueLSSU(FRAME_STATUS_INDICATION_N);
                     }
-                    // if (this.T4_TIMEOUT == this.T4_TIMEOUT_EMERGENCY) {
-                    // queueLSSU(FRAME_STATUS_INDICATION_E);
-                    // } else {
-                    //
-                    // queueLSSU(FRAME_STATUS_INDICATION_N);
-                    // }
+
                     break;

                 default:

Reply via email to