mirror of
https://github.com/intel/llvm.git
synced 2026-01-23 16:06:39 +08:00
[NFC][clang] Fix static analyzer concerns
DelegatingDeserializationListener frees resources in the destructor but doesn't have user-written copy c'tor or assignment operator, so copying it using default ones can cause double free. Reviewed By: aaron.ballman Differential Revision: https://reviews.llvm.org/D156405
This commit is contained in:
@@ -61,6 +61,11 @@ public:
|
||||
delete Previous;
|
||||
}
|
||||
|
||||
DelegatingDeserializationListener(const DelegatingDeserializationListener &) =
|
||||
delete;
|
||||
DelegatingDeserializationListener &
|
||||
operator=(const DelegatingDeserializationListener &) = delete;
|
||||
|
||||
void ReaderInitialized(ASTReader *Reader) override {
|
||||
if (Previous)
|
||||
Previous->ReaderInitialized(Reader);
|
||||
|
||||
Reference in New Issue
Block a user