]> granicus.if.org Git - clang/commit
Implement poisoning of only class members in dtor, as opposed to also poisoning field...
authorNaomi Musgrave <nmusgrave@google.com>
Wed, 12 Aug 2015 21:37:40 +0000 (21:37 +0000)
committerNaomi Musgrave <nmusgrave@google.com>
Wed, 12 Aug 2015 21:37:40 +0000 (21:37 +0000)
commit8dbbf3578a9a5d063232b59e558e5fe46e2cd42c
treec078397f27ef9e9b3bbac075210f12c80ccea67f
parent81b6681f00874c2db2471447c2d9f7835aa7723d
Implement poisoning of only class members in dtor, as opposed to also poisoning fields inherited from base classes.
Verify emitted code for derived class with virtual destructor sanitizes its members only once.
Changed emission order for dtor callback, so only the last dtor for a class emits the sanitizing callback, while ensuring that class members are poisoned before base class destructors are invoked.
Skip poisoning of members, if class has no fields.
Removed patch file containing extraneous changes.

Summary: Poisoning applied to only class members, and before dtors for base class invoked

Reviewers: eugenis, kcc

Differential Revision: http://reviews.llvm.org/D11951

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@244819 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/CGClass.cpp
test/CodeGenCXX/sanitize-dtor-callback.cpp
test/CodeGenCXX/sanitize-dtor-derived-class.cpp [new file with mode: 0644]
test/CodeGenCXX/sanitize-dtor-fn-attribute.cpp