Skip to content

Commit

Permalink
Merge pull request #3490 from karalabe/fix-miner-api
Browse files Browse the repository at this point in the history
eth: fix miner start API to accept int, not hexint
  • Loading branch information
karalabe authored Dec 23, 2016
2 parents 115364b + 89a3226 commit 3e3edcc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions eth/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -138,13 +138,13 @@ func NewPrivateMinerAPI(e *Ethereum) *PrivateMinerAPI {

// Start the miner with the given number of threads. If threads is nil the number of
// workers started is equal to the number of logical CPU's that are usable by this process.
func (s *PrivateMinerAPI) Start(threads *hexutil.Uint) (bool, error) {
func (s *PrivateMinerAPI) Start(threads *int) (bool, error) {
s.e.StartAutoDAG()
var err error
if threads == nil {
err = s.e.StartMining(runtime.NumCPU())
} else {
err = s.e.StartMining(int(*threads))
err = s.e.StartMining(*threads)
}
return err == nil, err
}
Expand Down

0 comments on commit 3e3edcc

Please # to comment.