Skip to content

Conversation

@maflcko
Copy link
Member

@maflcko maflcko commented Feb 1, 2019

Marked as "doc" because it didn't change the bitcoind on my system with default configure settings for both gcc and clang.

@practicalswift
Copy link
Contributor

Concept ACK

Thanks for adding this missing annotation.

@maflcko maflcko force-pushed the Mf1902-docLoc branch 2 times, most recently from fa5349e to fa36350 Compare February 1, 2019 20:30
Copy link
Contributor

@promag promag left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Concept ACK.

* Mark one block file as pruned.
*/
void PruneOneBlockFile(const int fileNumber);
void PruneOneBlockFile(const int fileNumber) EXCLUSIVE_LOCKS_REQUIRED(cs_main);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this necessary?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Without it I get:

  CXX      wallet/libbitcoin_wallet_a-wallet.o
validation.cpp:3623:28: warning: reading variable 'mapBlockIndex' requires holding mutex 'cs_main' [-Wthread-safety-analysis]
    for (const auto& entry : mapBlockIndex) {
                           ^
validation.cpp:3623:28: warning: reading variable 'mapBlockIndex' requires holding mutex 'cs_main' [-Wthread-safety-analysis]
  CXX      wallet/libbitcoin_wallet_a-walletdb.o

@Empact
Copy link
Contributor

Empact commented Feb 4, 2019

utACK fa2a69f

maflcko pushed a commit to maflcko/bitcoin-core that referenced this pull request Feb 6, 2019
fa2a69f doc: Add cs_main lock annotations for mapBlockIndex (practicalswift)

Pull request description:

  Marked as "doc" because it didn't change the bitcoind on my system with default configure settings for both gcc and clang.

Tree-SHA512: ba203f16c1cdc834a61c65bb5fb20bbaf7d8bff0c3a1b8ef46bc1d3669092191221e26abd7e580efab2f9bd5a992dc363251f1b68c6cd68f8204d62675868cf1
@maflcko maflcko merged commit fa2a69f into bitcoin:master Feb 6, 2019
@maflcko maflcko deleted the Mf1902-docLoc branch February 6, 2019 18:30
deadalnix pushed a commit to Bitcoin-ABC/bitcoin-abc that referenced this pull request Mar 26, 2020
Summary:
```
Previously the argument would be untouched if the first block scan
failed. This makes the behavior predictable, and consistent with the
documentation.
```

Backport of core [[bitcoin/bitcoin#14957 | PR14957]] and the remaining of [[bitcoin/bitcoin#15321 | PR15321]] (see D5238).

Depends on D5563.

Test Plan:
With Clang:
  cmake -GNinja .. -DCMAKE_BUILD_TYPE=Debug -DENABLE_WERROR=ON
  ninja all check check-functional

Reviewers: #bitcoin_abc, deadalnix

Reviewed By: #bitcoin_abc, deadalnix

Differential Revision: https://reviews.bitcoinabc.org/D5564
LarryRuane pushed a commit to LarryRuane/zcash that referenced this pull request Apr 29, 2021
LarryRuane pushed a commit to LarryRuane/zcash that referenced this pull request Jun 1, 2021
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Dec 16, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants