diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2017-09-16 07:17:53 +0200 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2017-09-16 07:40:45 +0200 |
commit | e278f86c536921032e8288625dc5f3af610f2ec8 (patch) | |
tree | addc48d38df39deda26e6b4804e2bec1622ea274 /src/support/lockedpool.cpp | |
parent | 09627b1dd41d1151a709d5ead82a924bf59e3d38 (diff) | |
parent | 1444c2e7d0a243690b960c1fefe5f36bf5ca7e54 (diff) |
Merge #11196: Switch memory_cleanse implementation to BoringSSL's to ensure memory clearing even with -lto
1444c2e Switch memory_cleanse implementation to BoringSSL's to ensure memory clearing even with link-time optimization. (Adam Langley)
Pull request description:
The implementation we currently use from OpenSSL prevents the compiler from optimizing away clensing operations on blocks of memory that are about to be released, but this protection is not extended to link-time optimization. This commit copies the solution cooked up by Google compiler engineers which uses inline assembly directives to instruct the compiler not to optimize out the call under any circumstances. As the code is in-lined, this has the added advantage of removing one more OpenSSL dependency.
Regarding license compatibility, Google's contributions to BoringSSL library, including this code, is made available under the ISC license, which is MIT compatible.
BoringSSL git commit: ad1907fe73334d6c696c8539646c21b11178f20f
Tree-SHA512: 8134998663c1501e3ce48fbbd6ab41de981f0855e3f4d25d2e86ff8056c917d82c751c88e9c39660319ebfbc8283dce594c3e4fc7f87080a212a2cdba57ea511
Diffstat (limited to 'src/support/lockedpool.cpp')
0 files changed, 0 insertions, 0 deletions