From a0d8eb2c245aa1245f61ac2c2dce7bde26a82479 Mon Sep 17 00:00:00 2001 From: Antonin Portelli Date: Tue, 23 Feb 2016 16:33:00 +0000 Subject: [PATCH] minor code cleaning --- programs/Hadrons/Application.cc | 5 +---- programs/Hadrons/Global.cc | 2 -- programs/Hadrons/Hadrons.cc | 6 ++++++ 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/programs/Hadrons/Application.cc b/programs/Hadrons/Application.cc index c8c44adc..5eb43363 100644 --- a/programs/Hadrons/Application.cc +++ b/programs/Hadrons/Application.cc @@ -42,10 +42,7 @@ Application::Application(const std::string parameterFileName) // destructor ////////////////////////////////////////////////////////////////// Application::~Application(void) -{ - LOG(Message) << "Grid is finalizing now" << std::endl; - Grid_finalize(); -} +{} // execute ///////////////////////////////////////////////////////////////////// void Application::run(void) diff --git a/programs/Hadrons/Global.cc b/programs/Hadrons/Global.cc index a560d71f..a8d8f22b 100644 --- a/programs/Hadrons/Global.cc +++ b/programs/Hadrons/Global.cc @@ -26,5 +26,3 @@ HadronsLogger Hadrons::HadronsLogError(1,"Error"); HadronsLogger Hadrons::HadronsLogWarning(1,"Warning"); HadronsLogger Hadrons::HadronsLogMessage(1,"Message"); HadronsLogger Hadrons::HadronsLogDebug(1,"Debug"); - - diff --git a/programs/Hadrons/Hadrons.cc b/programs/Hadrons/Hadrons.cc index 853de83c..d53ca497 100644 --- a/programs/Hadrons/Hadrons.cc +++ b/programs/Hadrons/Hadrons.cc @@ -33,6 +33,8 @@ int main(int argc, char *argv[]) std::exit(EXIT_FAILURE); } parameterFileName = argv[1]; + + // initialization Grid_init(&argc, &argv); HadronsLogError.Active(GridLogError.isActive()); HadronsLogWarning.Active(GridLogWarning.isActive()); @@ -45,5 +47,9 @@ int main(int argc, char *argv[]) application.run(); + // epilogue + LOG(Message) << "Grid is finalizing now" << std::endl; + Grid_finalize(); + return EXIT_SUCCESS; }