From c83f592d4e1d74dac8adc480c8b8a43f7ad05d67 Mon Sep 17 00:00:00 2001 From: Scott Date: Tue, 9 Feb 2016 20:48:32 -0500 Subject: [PATCH] Fix PHP 5.6 intdiv --- src/SeedSpring.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/SeedSpring.php b/src/SeedSpring.php index 25b2e43..a6a985e 100644 --- a/src/SeedSpring.php +++ b/src/SeedSpring.php @@ -229,7 +229,8 @@ protected function getNonce($increment = 0) $nonce = \chr($ctr & 0xFF) . $nonce; $ctr >>= 8; } - $this->counter += (int) \floor($increment + ($increment % 16) / 16); + $incr = (int) \floor(($increment + ($increment % 16)) / 16); + $this->counter += $incr; return \str_pad($nonce, 16, "\0", STR_PAD_LEFT); } }