Skip to content
This repository was archived by the owner on Oct 28, 2021. It is now read-only.

Commit d4d96c0

Browse files
authored
Merge pull request #4105 from ethereum/makeFutureBlocksFlexible
Parse the "allowFutureBlocks" in a more flexible manner.
2 parents 35c67e7 + 4e9302e commit d4d96c0

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

libethereum/ChainParams.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,11 @@ ChainParams ChainParams::loadConfig(string const& _json, h256 const& _stateRoot)
7373
else
7474
{
7575
if (i.first == "allowFutureBlocks")
76-
cp.otherParams[i.first] = i.second.get_bool();
76+
{
77+
// The value in otherParams is irrelevant, we only check for the presence of the key.
78+
if (i.second.type() != json_spirit::bool_type || i.second.get_bool())
79+
cp.otherParams[i.first] = "true";
80+
}
7781
}
7882
}
7983

0 commit comments

Comments
 (0)