Page MenuHomePhabricator

Prevent null pointer dereference in addWallet
AbandonedPublic

Authored by jasonbcox on Wed, Nov 27, 19:26.

Details

Reviewers
deadalnix
Group Reviewers
Restricted Project
Summary

qt/test/apptests.cpp fails on Xenial, likely due to a race condition
as we do not see this behavior on Buster. This behavior appears to be fixed by
backporting PR15101 but has many dependencies (see T697). Until PR15101 is backported,
this will provide a quick bandaid so that developers working on Xenial machines can continue working.

The failure case for this is that payment server slots/signals are not correctly connected. Depending on how the race condition manifests in the wild, bitcoin-qt may fail for BIP70 payments. I expect this to be low user impact considering
the few users using the wallet software, and the fewer who use it for BIP70 payments.

Test Plan

ninja check

Diff Detail

Repository
rABC Bitcoin ABC
Branch
xenial-bandaid
Lint
Lint OK
Unit
No Unit Test Coverage
Build Status
Buildable 8312
Build 14643: Bitcoin ABC Buildbot
Build 14642: arc lint + arc unit

Event Timeline

jasonbcox created this revision.Wed, Nov 27, 19:26
jasonbcox edited the summary of this revision. (Show Details)Wed, Nov 27, 20:03
deadalnix requested changes to this revision.Wed, Nov 27, 23:15

If there is a race condition, then the proper solution is a lock or something lock free using atomics, not a null check that has no ordering constraint.

This revision now requires changes to proceed.Wed, Nov 27, 23:15
jasonbcox abandoned this revision.Tue, Dec 3, 00:24