commit | 9355fadefa5ab9c9fbae6f074e2dc9cdd8e8052f | [log] [tgz] |
---|---|---|
author | David Drysdale <drysdale@google.com> | Mon Jan 24 08:07:34 2022 +0000 |
committer | Armelle Laine <armellel@google.com> | Thu Jun 09 06:00:29 2022 +0000 |
tree | 32ee9e4ba582f27435a25719377256e9badd85c4 | |
parent | fdeafb864cefd667ef85be50fdfa863339046791 [diff] |
Use new (std::nothrow) throughout If code uses "normal" `new`, the compiler is allowed to assume that `nullptr` is never returned, even if built with -fno-exceptions. Use `new (std::nothrow)` throughout so that `nullptr` gets returned and can (in some cases) be handled. Bug: 215451239 Test: VtsAidlKeyMintTargetTest Ignore-AOSP-First: Cherry pick from AOSP Change-Id: Ied97ce946c0fbfbd5449c533e7ce1acbd0f595c5 (cherry picked from commit b80ef359b047a6bb72947b582102a979568f5c30)