Exemplo n.º 1
0
 internal void CheckShareAsync(BaseMiner miner, BlockHeader block)
 {
     Task.Run(() =>  CheckShare(miner, block));
 }
Exemplo n.º 2
0
 internal void CheckShare(BaseMiner miner, BlockHeader block)
 {
     var data = new WorkResult();
     data.Time = block.Time;
     data.Nonce = block.Nonce;
     data.TaskUID = block.TaskUID;
     string hash = block.CalculateHash().ToString();
     try
     {
         var res = CheckWork(data);
         miner.ProcessShareStatus(res ,hash);
     }
     catch (Exception ex)
     {
         miner.ProcessShareStatus(new OperationResult() { Message = "Send error" }, hash);
     }
 }