mirror of
https://github.com/LBRYFoundation/pool.git
synced 2025-09-05 05:15:17 +00:00
backend: ignore btc net hash overflow #141
could be due to the unit for the network_hash.. quick fix
This commit is contained in:
parent
41afa22d0d
commit
17875d358f
1 changed files with 5 additions and 1 deletions
|
@ -278,9 +278,13 @@ function BackendCoinsUpdate()
|
|||
}
|
||||
}
|
||||
|
||||
if($coin->network_hash)
|
||||
if($coin->network_hash) {
|
||||
$coin->network_ttf = $coin->difficulty * 0x100000000 / $coin->network_hash;
|
||||
|
||||
// BTC network_hash unit may be wrong... prevent db int(11) overflow
|
||||
if($coin->network_ttf > 9999999999) $coin->network_ttf = 0;
|
||||
}
|
||||
|
||||
if(isset($pool_rate[$coin->algo]))
|
||||
$coin->pool_ttf = $coin->difficulty * 0x100000000 / $pool_rate[$coin->algo];
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue