Skip to content
Snippets Groups Projects
Commit 45bd7d50 authored by Cédric Moreau's avatar Cédric Moreau
Browse files

[fix] #1126 The prefix gets mixed with core ID when we have 10+ cores

parent d595e742
No related branches found
No related tags found
No related merge requests found
...@@ -5,7 +5,7 @@ import {ConfDTO} from "../../../lib/dto/ConfDTO" ...@@ -5,7 +5,7 @@ import {ConfDTO} from "../../../lib/dto/ConfDTO"
import {Constants} from "./constants" import {Constants} from "./constants"
import {KeyGen} from "../../../lib/common-libs/crypto/keyring" import {KeyGen} from "../../../lib/common-libs/crypto/keyring"
import {dos2unix} from "../../../lib/common-libs/dos2unix" import {dos2unix} from "../../../lib/common-libs/dos2unix"
import {rawer} from "../../../lib/common-libs/index"; import {rawer} from "../../../lib/common-libs/index"
const moment = require('moment'); const moment = require('moment');
const querablep = require('querablep'); const querablep = require('querablep');
...@@ -87,7 +87,7 @@ function beginNewProofOfWork(stuff:any) { ...@@ -87,7 +87,7 @@ function beginNewProofOfWork(stuff:any) {
currentCPU = conf.cpu || Constants.DEFAULT_CPU; currentCPU = conf.cpu || Constants.DEFAULT_CPU;
prefix = parseInt(conf.prefix || prefix) prefix = parseInt(conf.prefix || prefix)
if (prefix && prefix < Constants.NONCE_RANGE) { if (prefix && prefix < Constants.NONCE_RANGE) {
prefix *= 10 * Constants.NONCE_RANGE prefix *= 100 * Constants.NONCE_RANGE
} }
const highMark = stuff.highMark; const highMark = stuff.highMark;
const turnDuration = stuff.turnDuration || TURN_DURATION_IN_MILLISEC const turnDuration = stuff.turnDuration || TURN_DURATION_IN_MILLISEC
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment