HomePhabricator

net: Add Clang thread safety annotations for guarded variables in the…

Description

net: Add Clang thread safety annotations for guarded variables in the networking code

Summary:

  • Add missing lock in CNode::copyStats(...)
  • Add missing locking annotations

This is a backport of Core PR13123

Depends on D4083

Test Plan:

cmake -GNinja -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ ..
ninja

Check that there are no thread safety analysis warnings.

Reviewers: #bitcoin_abc, Fabien

Reviewed By: #bitcoin_abc, Fabien

Differential Revision: https://reviews.bitcoinabc.org/D4084

Details

Provenance
practicalswift <practicalswift@users.noreply.github.com>Authored on Oct 8 2018, 13:33
deadalnixCommitted on Sep 14 2019, 16:57
deadalnixPushed on Sep 15 2019, 08:22
Reviewer
Restricted Project
Differential Revision
D4084: net: Add Clang thread safety annotations for guarded variables in the networking code
Parents
rSTAGING57c2fde3f33f: Report minfeefilter value in getpeerinfo rpc
Branches
Unknown
Tags
Unknown