Page MenuHomePhabricator

Make functions in validation.cpp static and pass chainparams
ClosedPublic

Authored by deadalnix on Jan 27 2018, 00:21.

Details

Summary

Fix bugs as per PR comment

Change bool static to static bool

Backport core's PR10201

Test Plan
make check
./test/functional/test_runner.py --extended

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

I see some parts of PR10201 were already done on D348, D689

https://github.com/bitcoin/bitcoin/pull/10201/files#diff-349fbb003d5ae550a2e8fa658e475880L356
(making CheckInputs static) seems to be omitted here, is that on purpose?

I see it is not static on current Core's master;
https://github.com/bitcoin/bitcoin/blob/master/src/validation.cpp#L1356

jasonbcox added inline comments.
src/validation.cpp
2954 ↗(On Diff #2748)

params -> chainParams

4535 ↗(On Diff #2748)

params is a vague name that could have future naming conflicts. Should be something like chainParams

jasonbcox requested changes to this revision.Jan 29 2018, 18:54
This revision now requires changes to proceed.Jan 29 2018, 18:54
deadalnix added inline comments.
src/validation.cpp
2954 ↗(On Diff #2748)

dito

4535 ↗(On Diff #2748)

It's called params everywhere.

This revision is now accepted and ready to land.Jan 30 2018, 17:04
This revision was automatically updated to reflect the committed changes.