From 01f94751ef47f0357e1b91648c3053ad6db3914e Mon Sep 17 00:00:00 2001 From: Dmitri Naumov <dmitri.naumov@ufz.de> Date: Wed, 27 Nov 2019 15:16:47 +0100 Subject: [PATCH] [BL/IO] Remove unused XMLQtInterface::isHashGood. --- BaseLib/IO/XmlIO/Qt/XMLQtInterface.cpp | 16 ++-------------- BaseLib/IO/XmlIO/Qt/XMLQtInterface.h | 3 --- 2 files changed, 2 insertions(+), 17 deletions(-) diff --git a/BaseLib/IO/XmlIO/Qt/XMLQtInterface.cpp b/BaseLib/IO/XmlIO/Qt/XMLQtInterface.cpp index eaff3740f61..1208448c2db 100644 --- a/BaseLib/IO/XmlIO/Qt/XMLQtInterface.cpp +++ b/BaseLib/IO/XmlIO/Qt/XMLQtInterface.cpp @@ -128,17 +128,5 @@ bool XMLQtInterface::checkHash() const WARN("File is valid but could not write hashfile!"); return true; } - -bool XMLQtInterface::isHashGood(const QByteArray &hash) const -{ - QByteArray fileHash = QCryptographicHash::hash(_fileData, QCryptographicHash::Md5); - if(hash != fileHash) - { - INFO("Hashfile does not match data ... checking file ..."); - return false; - } - return true; -} - -} // end namespace IO -} // end namespace BaseLib +} // namespace IO +} // namespace BaseLib diff --git a/BaseLib/IO/XmlIO/Qt/XMLQtInterface.h b/BaseLib/IO/XmlIO/Qt/XMLQtInterface.h index c33a025246a..a5671efc9dd 100644 --- a/BaseLib/IO/XmlIO/Qt/XMLQtInterface.h +++ b/BaseLib/IO/XmlIO/Qt/XMLQtInterface.h @@ -46,9 +46,6 @@ protected: /// If no hash file exists, the xml-file is validated and a hash file is written if the xml-file was valid. bool checkHash() const; - /// Checks if the given file is conform to the given hash. - bool isHashGood(const QByteArray &hash) const; - QString _schemaFile; /// Caches the actual file contents when reading. -- GitLab