Page MenuHomePhabricator

Fix undefined behavior in rcu_tests
ClosedPublic

Authored by Fabien on Jul 25 2019, 14:49.

Details

Summary

This diff removes a call in rcu_tests which triggers the null pointer
dereference check from UBSAN. gptr internal pointer is initialized to
nullptr and called with the * operator.
This does not impact the test coverage as the operator is tested later
in the test case.

Test Plan
../configure --enable-debug --with-sanitizers=undefined
make
./src/test/test_bitcoin -t rcu_tests

Diff Detail

Repository
rABC Bitcoin ABC
Branch
fix_ub_in_rcu_tests
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 6962
Build 11971: Bitcoin ABC Buildbot (legacy)
Build 11970: arc lint + arc unit