Make worker more resistant to weird data in ethereum blockchain
parent
4a216fa647
commit
5e170b8dd8
|
@ -473,7 +473,11 @@ func (w *Worker) getEthereumTypeAddressBalances(addrDesc bchain.AddressDescripto
|
|||
}
|
||||
b, err = w.chain.EthereumTypeGetErc20ContractBalance(addrDesc, c.Contract)
|
||||
if err != nil {
|
||||
return nil, nil, nil, errors.Annotatef(err, "EthereumTypeGetErc20ContractBalance %v %v", addrDesc, c.Contract)
|
||||
// return nil, nil, nil, errors.Annotatef(err, "EthereumTypeGetErc20ContractBalance %v %v", addrDesc, c.Contract)
|
||||
glog.Warningf("EthereumTypeGetErc20ContractBalance addr %v, contract %v, %v", addrDesc, c.Contract, err)
|
||||
}
|
||||
if b == nil {
|
||||
b = &big.Int{}
|
||||
}
|
||||
erc20t[i] = Erc20Token{
|
||||
Balance: bchain.AmountToDecimalString(b, ci.Decimals),
|
||||
|
|
Loading…
Reference in New Issue