MCPcopy Create free account
hub / github.com/BTCGPU/BTCGPU / IsScriptWitnessEnabled

Function IsScriptWitnessEnabled

src/validation.cpp:1782–1785  ·  view source on GitHub ↗

0.13.0 was shipped with a segwit deployment defined for testnet, but not for mainnet. We no longer need to support disabling the segwit deployment except for testing purposes, due to limitations of the functional test environment. See test/functional/p2p-segwit.py.

Source from the content-addressed store, hash-verified

1780// except for testing purposes, due to limitations of the functional test
1781// environment. See test/functional/p2p-segwit.py.
1782static bool IsScriptWitnessEnabled(const Consensus::Params& params)
1783{
1784 return params.vDeployments[Consensus::DEPLOYMENT_SEGWIT].nTimeout != 0;
1785}
1786
1787static unsigned int GetBlockScriptFlags(const CBlockIndex* pindex, const Consensus::Params& consensusparams) {
1788 AssertLockHeld(cs_main);

Callers 1

GetBlockScriptFlagsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected