Different type to mark Mutex at global scope

Synopsis

Declared in <sync.h>

class GlobalMutex
    : public Mutex

Description

Thread safety analysis can't handle negative assertions about mutexes with global scope well, so mark them with a separate type, and eventually move all the mutexes into classes so they are not globally visible.

See: https://github.com/bitcoin/bitcoin/pull/20272#issuecomment‐720755781

Base Classes

Name

Description

Mutex

Wrapped mutex: supports waiting but not recursive locking

Created with MrDocs