Commit Graph

14944 Commits

Author SHA1 Message Date
Jack Grigg 434f32151c Fix include guards 2021-04-14 12:54:12 +12:00
Jack Grigg b2f01b1e4a Remove duplicate / unused includes 2021-04-14 12:53:06 +12:00
Jack Grigg b6162e5b4f scripted-diff: Remove direct usages of boost::filesystem
These were merged in an old PR that was created before we backported
src/fs.h.

-BEGIN VERIFY SCRIPT-
sed -i 's/boost::filesystem/fs/g' ./src/addrdb.*
-END VERIFY SCRIPT-
2021-04-14 12:52:15 +12:00
Homu 3e53b40e25 Auto merge of #5055 - str4d:release-v4.4.0-rc1, r=str4d
Release v4.4.0-rc1
2021-04-09 06:43:08 +00:00
Jack Grigg 30f68da525 make-release.py: Updated release notes and changelog for 4.4.0-rc1. 2021-04-09 17:40:36 +12:00
Jack Grigg 253da68a2d make-release.py: Updated manpages for 4.4.0-rc1. 2021-04-09 17:40:36 +12:00
Jack Grigg f4d88aec20 make-release.py: Versioning changes for 4.4.0-rc1. 2021-04-09 17:32:49 +12:00
Homu 71f39c5013 Auto merge of #5047 - str4d:bump-dep-postpones, r=daira
Bump dependency postponements
2021-04-08 15:35:33 +00:00
Homu cbc475fd48 Auto merge of #4965 - str4d:secp256k1-update, r=daira
Update libsecp256k1 subtree

The first subtree merge brings us to the same commit as upstream (bitcoin/bitcoin#20257).

The second subtree merged brings us to current master, which includes most of our local changes.

After this, our remaining local changes are:
- 75f9f8f95b (the change to `secp256k1_scalar_get_b32`)
- e917cb614f (compile with C99)
2021-04-08 14:08:45 +00:00
Homu 76d3adc564 Auto merge of #5052 - daira:windows-ntdll-regression, r=daira
Link with ntdll library on Windows

This fixes a regression for builds targeting Windows introduced in #4947. It also includes a minor cleanup to fix a build warning.
closes #5051
2021-04-06 19:35:50 +00:00
Daira Hopwood 2a26a9726c Cleanup: get the definition of ENABLE_VIRTUAL_TERMINAL_PROCESSING from wincon.h.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2021-04-06 16:41:28 +01:00
Daira Hopwood f52260253c configure.ac: tidy up spacing.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2021-04-06 16:40:31 +01:00
Daira Hopwood 78ab48669d configure.ac: Add check for ntdll on Windows.
This fixes #5051, which is a regression caused by the dependency on the ntapi crate
(via mio, via tokio) added by #4947.

Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2021-04-06 16:39:45 +01:00
Jack Grigg da77a3db73 qa: Postpone Boost 1.75.0
https://github.com/zcash/zcash/issues/4945 remains unresolved.
2021-04-03 17:26:16 +13:00
Jack Grigg c0e146d3f4 qa: Postpone updates that require CMake in the build system
We still aren't committing to that dependency yet.
2021-04-03 17:26:16 +13:00
Jack Grigg d1c6647934 qa: Point univalue update checker at correct upstream
Bitcoin Core doesn't actually use tags for managing versions of their
forked dependencies, so we should separately rework this logic for all
of the subtree-managed dependencies. But this at least prevents false
positives.
2021-04-03 17:15:24 +13:00
Homu c96986452a Auto merge of #4988 - nuttycom:feature/3722-feature_flags, r=str4d
Add feature flagging infrastructure to consensus parameters.

Factors out feature flagging bits from #4480

Fixes #3722
2021-04-03 01:29:50 +00:00
Homu 49ffee3f20 Auto merge of #5012 - LarryRuane:upstream-locking-0.15, r=str4d
Bitcoin 0.15 locking PRs

These are locking changes from upstream (bitcoin core) release 0.15, oldest to newest (when merged to the master branch).

Each commit also includes a reference both to the PR and the upstream commit.

- bitcoin/bitcoin#9497
2021-04-02 23:59:56 +00:00
Kris Nuttycombe c4305fc6f3 CurrentTxVersionInfo should return SPROUT_MIN_CURRENT_VERSION pre-overwinter. 2021-04-02 17:04:02 -06:00
Jeremy Rubin a314cdba56 Add CheckQueue Tests
zcash: cherry picked from commit 96c7f2c3458950061b057fcd3daaf47b57e6bac7
zcash: https://github.com/bitcoin/bitcoin/pull/9497
2021-04-02 12:22:48 -06:00
Jeremy Rubin 8e67b36e86 Fix CCheckQueue IsIdle (potential) race condition and remove dangerous constructors.
zcash: cherry picked from commit e2073424fd5a185781750347fbfbb0c108ef66fd
zcash: https://github.com/bitcoin/bitcoin/pull/9497
2021-04-02 12:22:48 -06:00
Kris Nuttycombe a901b57d98 Address review comments. 2021-04-02 09:45:09 -06:00
Kris Nuttycombe 041d363232 Merge remote-tracking branch 'upstream/master' into feature/3722-feature_flags 2021-04-02 09:02:16 -06:00
Homu 80e66e7daa Auto merge of #5009 - LarryRuane:upstream-locking-0.14, r=str4d
Bitcoin 0.14 locking PRs

These are locking changes from upstream (bitcoin core) release 0.14, oldest to newest (when merged to the master branch).

Each commit also includes a reference both to the PR and the upstream commit.

- bitcoin/bitcoin#8472
- bitcoin/bitcoin#8606
  - Excludes a lock move because we don't have bitcoin/bitcoin#7840 which this move was partially-reverting.
- bitcoin/bitcoin#9230
  - Only first commit (we don't have `LogTimestampStr` anymore).
- bitcoin/bitcoin#9243
  - Only the sixth commit, excluding `IsArgSet` locking (we haven't pulled that function in yet).
- bitcoin/bitcoin#9626
  - The cherry-picked commit does not match the upstream at all, but the resulting lock is useful.
- bitcoin/bitcoin#9679
- bitcoin/bitcoin#9227
- bitcoin/bitcoin#9698
  - Excludes change to `CConnman::PushMessage` in second commit (which we don't have yet).
- bitcoin/bitcoin#9708
- bitcoin/bitcoin#9771
2021-04-02 01:03:27 +00:00
Russell Yanofsky 4fd7387cef Add missing cs_wallet lock that triggers new lock held assertion
A new AssertLockHeld(cs_wallet) call was added in commit a58370e
"Dedup nTimeFirstKey update logic" (part of PR #9108).

The lock held assertion will fail when loading prexisting wallets files from
before the #9108 merge that have watch-only keys.

zcash: cherry picked from commit 07afcd6379bb46ace5856f6a47a9188cf9aed2ea
zcash: https://github.com/bitcoin/bitcoin/pull/9771
2021-04-02 12:55:48 +13:00
Matt Corallo c9e2172eb6 Move CNode::addrLocal access behind locked accessors
zcash: cherry picked from commit db2dc7a58cb0a3df58188b748df8e0d04ba76f00
zcash: https://github.com/bitcoin/bitcoin/pull/9708
2021-04-02 12:55:48 +13:00
Matt Corallo 116deeec5b Move CNode::addrName accesses behind locked accessors
zcash: cherry picked from commit 036073bf87c07f8d69e39168dd93a52f1aafe85c
zcash: https://github.com/bitcoin/bitcoin/pull/9708
2021-04-02 12:55:48 +13:00
Matt Corallo e6eac19062 Make nTimeBestReceived atomic
zcash: cherry picked from commit d8f2b8a8c032b83a3bd90750e58abaeece7e34e7
zcash: https://github.com/bitcoin/bitcoin/pull/9708
2021-04-02 12:55:48 +13:00
Matt Corallo 78e0b89750 Move [clean|str]SubVer writes/copyStats into a lock
zcash: cherry picked from commit 22b4966a29501c4f3f2e970ac5008fbd91e665a9
zcash: https://github.com/bitcoin/bitcoin/pull/9708
2021-04-02 12:55:48 +13:00
Matt Corallo 676e7814f3 Make nServices atomic
zcash: cherry picked from commit 0f3187261519c7568ef4211ce12b9740a3c1200f
zcash: https://github.com/bitcoin/bitcoin/pull/9708
2021-04-02 12:55:48 +13:00
Matt Corallo 651c46a4b3 Make nStartingHeight atomic
zcash: cherry picked from commit 96f42d8a12871b8d5c4e31fd27d8135f97c6b3e0
zcash: https://github.com/bitcoin/bitcoin/pull/9708
2021-04-02 12:55:48 +13:00
Matt Corallo c2c43e39b2 Access fRelayTxes with cs_filter lock in copyStats
zcash: cherry picked from commit 512731bed0782f10092de35a960153b17ecc11eb
zcash: https://github.com/bitcoin/bitcoin/pull/9708
2021-04-02 12:55:48 +13:00
Matt Corallo 5d3586f707 Avoid copying CNodeStats to make helgrind OK with buggy std::string
zcash: cherry picked from commit ae683c1b1960b32134f5a5a29504691c91f39cf3
zcash: https://github.com/bitcoin/bitcoin/pull/9708
2021-04-01 14:29:40 -06:00
Matt Corallo 208a1a5867 Make nTimeConnected const in CNode
zcash: cherry picked from commit 644f1234e22626a7b5618a1dae60a8457a4063b1
zcash: https://github.com/bitcoin/bitcoin/pull/9708
2021-04-01 14:29:40 -06:00
Cory Fields 51fb0415c9 net: fix a few races. Credit @TheBlueMatt
These are (afaik) all long-standing races or concurrent accesses. Going
forward, we can clean these up so that they're not all individual atomic
accesses.

- Reintroduce cs_vRecv to guard receive-specific vars
- Lock vRecv/vSend for CNodeStats
- Make some vars atomic.
- Only set the connection time in CNode's constructor so that it doesn't change

zcash: cherry picked from commit 321d0fc6b6624c65508f8b9059418cb936f0bbbe
zcash: https://github.com/bitcoin/bitcoin/pull/9708
2021-04-01 14:29:40 -06:00
Cory Fields 9825103a10 net: add a lock around hSocket
zcash: cherry picked from commit 9a0b784deaab6b9fffcab227d928987b981d0572
zcash: https://github.com/bitcoin/bitcoin/pull/9698
2021-04-01 14:29:40 -06:00
Cory Fields 8a26f4b800 net: rearrange so that socket accesses can be grouped together
zcash: cherry picked from commit 45e2e085612463dd9cca9f1b221733afa6d52991
zcash: https://github.com/bitcoin/bitcoin/pull/9698
2021-04-01 14:29:40 -06:00
Patrick Strateman 0658e2d0d3 Make nWalletDBUpdated atomic to avoid a potential race.
zcash: cherry picked from commit d63ff6265b0c6ae30efcbb9120d4db419606198a
zcash: https://github.com/bitcoin/bitcoin/pull/9227
2021-04-01 14:29:40 -06:00
Matt Corallo 6cc2c45eb9 Access WorkQueue::running only within the cs lock.
This removes a "race" between Interrupt() and Run(), though it
should not effect any of our supported platforms.

zcash: cherry picked from commit 7b2d96b634f9fd283480caf3bece56138d0587e3
zcash: https://github.com/bitcoin/bitcoin/pull/9679
2021-04-01 14:29:40 -06:00
Matt Corallo 024a94663c Ensure cs_vNodes is held when using the return value from FindNode
zcash: cherry picked from commit 3c37dc40d39e1a1e56b6b0d3e660626a78656d4f
zcash: https://github.com/bitcoin/bitcoin/pull/9626
2021-04-01 14:29:40 -06:00
Matt Corallo f60964c374 Lock mapArgs/mapMultiArgs access in util
zcash: cherry picked from commit 4e048142a5e45d622355dad92ade192ad4769ca3
zcash: https://github.com/bitcoin/bitcoin/pull/9243
2021-04-01 14:29:40 -06:00
Matt Corallo cafc3f845d Fix race when accessing std::locale::classic()
See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78552

zcash: cherry picked from commit 507145d78595e052ce13368e122f72c85093992c
zcash: https://github.com/bitcoin/bitcoin/pull/9230
2021-04-01 14:29:40 -06:00
Pieter Wuille 451600b9a6 Fix some locks
This makes sure that cs_filter is never held while taking cs_main
or CNode::cs_vSend.

zcash: cherry picked from commit 144ed76ea0b38b7c21b224501964f8a2c65c4bb6
zcash: https://github.com/bitcoin/bitcoin/pull/8606
2021-04-01 14:29:40 -06:00
Pavel Janík 27d328030c Do not shadow LOCK's criticalblock variable for LOCK inside LOCK
zcash: cherry picked from commit 33d15a3a76d073986337adcd62646d93e7ba223f
zcash: https://github.com/bitcoin/bitcoin/pull/8472
2021-04-01 14:29:40 -06:00
Homu e39441ff8b Auto merge of #5044 - daira:delete-spare-fr-addrs, r=daira
Delete spare mainnet Founders' Reward addresses that will never be used

These addresses were originally intended as fallbacks if an FR address was compromised.
There is no need to retain them in the code given that the FR has ended.

Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2021-04-01 13:02:48 +00:00
Daira Hopwood f5d53f953c Delete spare mainnet Founders' Reward addresses that will never be used.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2021-04-01 13:03:06 +01:00
Homu 2d3b58c993 Auto merge of #4999 - LarryRuane:upstream-locking-0.13, r=str4d
Bitcoin 0.13 locking PRs

These are locking changes from upstream (bitcoin core) release 0.13, oldest to newest (when they were merged to the master branch).
- https://github.com/bitcoin/bitcoin/pull/7846
- https://github.com/bitcoin/bitcoin/pull/7913
- https://github.com/bitcoin/bitcoin/pull/8016
  - second commit only; first commit, test changes, are already done
- https://github.com/bitcoin/bitcoin/pull/7942

This PR does not include:
 - https://github.com/bitcoin/bitcoin/pull/8244 27f8126ff3
   -  zcash requires locking `cs_main` in this instance (`getrawmempool()` calls `mempoolToJSON()`, which calls `chainActive.Height()`).
2021-04-01 05:46:27 +00:00
Homu 51ca3b955a Auto merge of #2939 - plutoforever:master, r=str4d
removed bashisms from build scripts

Closes https://github.com/zcash/zcash/issues/2677
2021-04-01 01:37:37 +00:00
Jack Grigg fb38cf0d90 lint: Fix false positive
shellcheck interprets the single-quoted string as arguments to echo, not
the string that echo echos. Switching to double quotes fixes the lint.
2021-04-01 14:30:35 +13:00
Jack Grigg a1903d2644 Remove usage of local from fetch-params.sh 2021-04-01 14:28:41 +13:00