diff src/main/java/com/glavsoft/rfb/protocol/ReceiverTask.java @ 380:aef5cbdd84ab

Fix compare SerialNumber flag
author innparusu
date Wed, 02 Sep 2015 17:33:06 +0900
parents 60abae693629
children 6a8b661367c6
line wrap: on
line diff
--- a/src/main/java/com/glavsoft/rfb/protocol/ReceiverTask.java	Tue Sep 01 16:50:40 2015 +0900
+++ b/src/main/java/com/glavsoft/rfb/protocol/ReceiverTask.java	Wed Sep 02 17:33:06 2015 +0900
@@ -231,9 +231,10 @@
             while (numberOfRectangles-- > 0) {
                 FramebufferUpdateRectangle rect = new FramebufferUpdateRectangle();
                 rect.fill(reader);
-                long time = System.currentTimeMillis();
-                if(rfb.isTreeManager() && rfb.checkDelay)
+                if(rfb.isTreeManager() && rfb.checkDelay) {
+                    long time = System.currentTimeMillis();
                     System.out.println(time + " : size : " + rect.width * rect.height);
+                }
                 Decoder decoder = decoders.getDecoderByType(rect.getEncodingType());
                 logger.finest(rect.toString() + (0 == numberOfRectangles ? "\n---" : ""));
                 if (decoder != null) {
@@ -365,7 +366,6 @@
         int addSerialNumFlag = reader.readInt32();
         long num = reader.readInt64();
         if (addSerialNumFlag == 1) {
-            rfb.setAddSerialNum(true);
             if(num != ++checkCounter) {
                 System.out.println("LostData" + (num - checkCounter));
                 checkCounter = num;