Code Duplication    Length = 8-8 lines in 2 locations

PHPDaemon/Clients/DNS/Connection.php 1 location

@@ 82-89 (lines=8) @@
79
            $this->setWatermark($this->pctSize);
80
            $this->state = self::STATE_PACKET;
81
        }
82
        if ($this->state === self::STATE_PACKET) {
83
            if (false === ($pct = $this->readExact($this->pctSize))) {
84
                return; // not enough data
85
            }
86
            $this->state = self::STATE_ROOT;
87
            $this->setWatermark(2);
88
            $this->onUdpPacket($pct);
89
        }
90
        goto start;
91
    }
92

PHPDaemon/Clients/Memcache/Connection.php 1 location

@@ 92-99 (lines=8) @@
89
            }
90
        }
91
92
        if ($this->state === self::STATE_DATA) {
93
            if (false === ($this->result = $this->readExact($this->valueLength))) {
94
                return; //we do not have a whole packet
95
            }
96
            $this->state = self::STATE_ROOT;
97
            $this->setWatermark(1);
98
            goto start;
99
        }
100
    }
101
}
102