]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
A class having virtual methods should have a virtual destructor
authorOtto <otto.moerbeek@open-xchange.com>
Wed, 28 Apr 2021 11:01:54 +0000 (13:01 +0200)
committerOtto <otto.moerbeek@open-xchange.com>
Wed, 28 Apr 2021 11:01:54 +0000 (13:01 +0200)
pdns/recursordist/logging.cc
pdns/recursordist/logging.hh

index b5da367fe4d232145963b9b297ce4465e9882fe0..ad796a8feaa79fde4b9db76676ac26a11e6aa75c 100644 (file)
@@ -135,6 +135,10 @@ namespace Logging
   Logger::Logger(std::shared_ptr<Logger> parent, boost::optional<const std::string> name, size_t lvl,  EntryLogger callback) : _parent(parent), _callback(callback), _name(name), _level(lvl)
   {
   }
+
+  Logger::~Logger()
+  {
+  }
 };
 
 std::shared_ptr<Logging::Logger> g_slog{nullptr};
index b8517284a04f9370775d967b887fbd4e138bf782..825ab36d03523e7bef3b8be7e0e6ff8a1c6ab190 100644 (file)
@@ -83,6 +83,7 @@ namespace Logging {
     Logger(EntryLogger callback);
     Logger(EntryLogger callback, boost::optional<const std::string> name);
     Logger(std::shared_ptr<Logger> parent, boost::optional<const std::string> name, size_t lvl,  EntryLogger callback);
+    virtual ~Logger();
 
     size_t getVerbosity() const;
     void setVerbosity(size_t verbosity);