Not the string again.
[core.git] / contrib / chash / chash.php
index b3bd3e63598970215d77fbdead54df8032935194..ed9265f38afb3585d976d65106998c3b780650ee 100644 (file)
@@ -53,7 +53,7 @@ function multipleHashString ($str) {
        // Now over-hash it
        for ($idx = 0; $idx < $totalHashes; $idx++) {
                // Over-hash the given hash
-               $hash = hashString($hash . $str);
+               $hash = hashString($hash);
        } // END - for
 
        // Return it
@@ -353,7 +353,7 @@ while (TRUE) {
                        // Only every second
                        if ($testTime >= 1) {
                                // Display hash rate
-                               print ('hashrate=' . $hashrate . ' hashes/sec,iterSecond=' . $iterSecond . ' iterations/sec' . PHP_EOL);
+                               print ('hashrate=' . round($hashrate) . ' hashes/sec,iterSecond=' . $iterSecond . ' iterations/sec' . PHP_EOL);
 
                                // Reset timer
                                $timeDisplay = microtime(TRUE);