In the MMIX LCG calculation, the right side calculation underlying type
is signed. This causes the undefined behavior sanitizer to detect a
signed integer overflow.
This diff sets the constants to unsigned long long to enforce the
underlying type to be unsigned and get rid of this error.
Details
Details
- Reviewers
deadalnix markblundeberg - Group Reviewers
Restricted Project - Commits
- rSTAGINGd478be9e220e: Fix undefined behavior in avalanche.cpp
rABCd478be9e220e: Fix undefined behavior in avalanche.cpp
With the UBSAN activated, run
test_bitcoin -t avalanche_tests
Diff Detail
Diff Detail
- Repository
- rABC Bitcoin ABC
- Lint
Lint Not Applicable - Unit
Tests Not Applicable
Event Timeline
Comment Actions
If the problem is that nodeid is signed, then this is what needs fixing, not all the constants.