From a078ff7293b7eb12151ab0865b63f36b7e0d434c Mon Sep 17 00:00:00 2001 From: Thomas Fischer <thomas.fischer@ufz.de> Date: Wed, 27 Feb 2019 07:30:48 +0100 Subject: [PATCH] [A/FileIO/PetrelInterface] Forbid copy constr. & co. cppcheck warning: class 'PetrelInterface' does not have a copy constructor which is recommended since the class contains a pointer to allocated memory. --- Applications/FileIO/PetrelInterface.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Applications/FileIO/PetrelInterface.h b/Applications/FileIO/PetrelInterface.h index ad09b3d3e3a..717777ff36a 100644 --- a/Applications/FileIO/PetrelInterface.h +++ b/Applications/FileIO/PetrelInterface.h @@ -39,6 +39,11 @@ public: std::string &unique_model_name, GeoLib::GEOObjects* obj); + PetrelInterface(PetrelInterface const& other) = delete; + PetrelInterface(PetrelInterface&& other) = delete; + PetrelInterface& operator=(PetrelInterface const&) = delete; + PetrelInterface& operator=(PetrelInterface&&) = delete; + private: void readPetrelSurface (std::istream &in); void readPetrelWellTrace (std::istream &in); -- GitLab