]> git.mxchange.org Git - hub.git/commitdiff
Added debugging, added missing (IMPORTANT) call of resetSerialNumber()
authorRoland Häder <roland@mxchange.org>
Sat, 19 May 2012 18:13:25 +0000 (18:13 +0000)
committerRoland Häder <roland@mxchange.org>
Sat, 19 May 2012 18:13:25 +0000 (18:13 +0000)
application/hub/main/handler/chunks/class_ChunkHandler.php
application/hub/main/helper/connection/class_BaseConnectionHelper.php
application/hub/main/package/fragmenter/class_PackageFragmenter.php

index f74cf99da39cc0682bdbb58b7f8f756243a4be42..ca3fa860030992e4a6f73d251502c999a326e187 100644 (file)
@@ -282,7 +282,7 @@ class ChunkHandler extends BaseHandler implements HandleableChunks, Registerable
                        $nextSerial = $this->getFragmenterInstance()->getNextHexSerialNumber();
 
                        // Debug output
-                       //* NOISY-DEBUG */ $this->debugOutput('CHUNK-HANDLER: serialNumber=' . $serialNumber . ',nextSerial=' . $nextSerial);
+                       /* NOISY-DEBUG */ $this->debugOutput('CHUNK-HANDLER: serialNumber=' . $serialNumber . ',nextSerial=' . $nextSerial);
 
                        // Is it not the same? Then re-request it
                        if ($serialNumber != $nextSerial) {
index c13e74d356291f8bd0af41ae4f2e041e6a1e606e..2fdc0f493e158b85ab0f6eb3981a8c58a37ed7b3 100644 (file)
@@ -383,6 +383,9 @@ class BaseConnectionHelper extends BaseHubHelper implements Registerable, Protoc
                // The helper's state must be 'connected'
                $this->getStateInstance()->validatePeerStateConnected();
 
+               // Reset serial number
+               $this->getFragmeneterInstance()->resetSerialNumber();
+
                // Cache buffer length
                $bufferSize = $this->getConfigInstance()->getConfigEntry($this->getProtocol() . '_buffer_length');
 
index 0a967973b569537aaf37e18aec814b96ef78476f..1f3adba5733203be7b206472c1def5ba94c4316d 100644 (file)
@@ -518,6 +518,10 @@ class PackageFragmenter extends BaseHubSystem implements Fragmentable, Registera
         * @return      void
         */
        public function resetSerialNumber () {
+               // Debug message
+               /* NOISY-DEBUG: */ $this->debugOutput('FRAGMENTER: Resetting serial number, previous=' . $this->serialNumber);
+
+               // Reset serial number
                $this->serialNumber = 0;
        }
 }