HomePhabricator

fix out-of-bounds memory write in key_tests

Description

fix out-of-bounds memory write in key_tests

Summary: Introduced by me in D2348. Thanks to Jason for catching this with ASan.

Test Plan:
make check

I ran ASan-compiled ./src/test/test_bitcoin --run_test=key_tests with and without this patch. Prior to patch it revealed memory error "WRITE of size 32"; afterwards it has no errors.

Reviewers: #bitcoin_abc, deadalnix

Reviewed By: #bitcoin_abc, deadalnix

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

Details

Provenance
Mark Lundeberg <36528214+markblundeberg@users.noreply.github.com>Authored on May 4 2019, 16:48
florianPushed on May 4 2019, 20:58
Reviewer
Restricted Project
Differential Revision
D2923: fix out-of-bounds memory write in key_tests
Parents
rSTAGINGf9ed1e8d3ff8: blockfilter: Remove sharp edge (uninitialized m_filter_type) when using theā€¦
Branches
Unknown
Tags
Unknown

Event Timeline

Mark Lundeberg <36528214+markblundeberg@users.noreply.github.com> committed rSTAGING8836ff3e2d5f: fix out-of-bounds memory write in key_tests (authored by Mark Lundeberg <36528214+markblundeberg@users.noreply.github.com>).May 4 2019, 20:02