From 13aaba029f477ffdb5deb0078c6b6544d83bc3f7 Mon Sep 17 00:00:00 2001 From: Frank Winklmeier <fwinkl@cern> Date: Fri, 24 Jul 2020 12:34:34 +0200 Subject: [PATCH] TrigT1CaloCalibUtils: Mark finalize as ATLAS_NOT_THREAD_SAFE `L1CaloPprPhos4ShapeMaker::finalize` is calling `m_signalShapes->Finalize()`, which is marked non-reentrant. So this method needs to be marked not-thread safe to avoid a compiler warning. --- Trigger/TrigT1/TrigT1CaloCalibUtils/CMakeLists.txt | 2 +- .../TrigT1CaloCalibUtils/L1CaloPprPhos4ShapeMaker.h | 12 ++++++------ .../src/L1CaloPprPhos4ShapeMaker.cxx | 4 ++-- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/Trigger/TrigT1/TrigT1CaloCalibUtils/CMakeLists.txt b/Trigger/TrigT1/TrigT1CaloCalibUtils/CMakeLists.txt index 44651b2ef65..6e5b814fd23 100644 --- a/Trigger/TrigT1/TrigT1CaloCalibUtils/CMakeLists.txt +++ b/Trigger/TrigT1/TrigT1CaloCalibUtils/CMakeLists.txt @@ -16,7 +16,7 @@ atlas_add_library( TrigT1CaloCalibUtilsLib INCLUDE_DIRS ${Boost_INCLUDE_DIRS} ${CORAL_INCLUDE_DIRS} ${CLHEP_INCLUDE_DIRS} PRIVATE_INCLUDE_DIRS ${ROOT_INCLUDE_DIRS} DEFINITIONS ${CLHEP_DEFINITIONS} - LINK_LIBRARIES ${Boost_LIBRARIES} ${CLHEP_LIBRARIES} ${CORAL_LIBRARIES} AthenaBaseComps AthenaKernel AthenaPoolUtilities CaloIdentifier CaloTriggerToolLib EventInfo GaudiKernel Identifier LArCablingLib LArElecCalib RegistrationServicesLib StoreGateLib TrigConfHLTData TrigConfL1Data TrigT1CaloCalibConditions TrigT1CaloCalibToolInterfaces TrigT1CaloCalibToolsLib TrigT1CaloCondSvcLib TrigT1CaloEventLib TrigT1CaloMonitoringToolsLib TrigT1CaloUtilsLib xAODTrigL1Calo + LINK_LIBRARIES ${Boost_LIBRARIES} ${CLHEP_LIBRARIES} ${CORAL_LIBRARIES} AthenaBaseComps AthenaKernel AthenaPoolUtilities CaloIdentifier CaloTriggerToolLib CxxUtils EventInfo GaudiKernel Identifier LArCablingLib LArElecCalib RegistrationServicesLib StoreGateLib TrigConfHLTData TrigConfL1Data TrigT1CaloCalibConditions TrigT1CaloCalibToolInterfaces TrigT1CaloCalibToolsLib TrigT1CaloCondSvcLib TrigT1CaloEventLib TrigT1CaloMonitoringToolsLib TrigT1CaloUtilsLib xAODTrigL1Calo PRIVATE_LINK_LIBRARIES ${ROOT_LIBRARIES} CaloDetDescrLib CaloEvent TrigT1CaloToolInterfaces TrigT1Interfaces xAODEventInfo ) atlas_add_component( TrigT1CaloCalibUtils diff --git a/Trigger/TrigT1/TrigT1CaloCalibUtils/TrigT1CaloCalibUtils/L1CaloPprPhos4ShapeMaker.h b/Trigger/TrigT1/TrigT1CaloCalibUtils/TrigT1CaloCalibUtils/L1CaloPprPhos4ShapeMaker.h index 25f944f7dda..93e7853e378 100644 --- a/Trigger/TrigT1/TrigT1CaloCalibUtils/TrigT1CaloCalibUtils/L1CaloPprPhos4ShapeMaker.h +++ b/Trigger/TrigT1/TrigT1CaloCalibUtils/TrigT1CaloCalibUtils/L1CaloPprPhos4ShapeMaker.h @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration */ // *************************************************************************** @@ -17,7 +17,8 @@ #include <map> // Athena includes -#include "AthenaBaseComps/AthAlgorithm.h" +#include "AthenaBaseComps/AthAlgorithm.h" +#include "CxxUtils/checker_macros.h" #include "GaudiKernel/ITHistSvc.h" #include "GaudiKernel/ToolHandle.h" @@ -65,11 +66,10 @@ class L1CaloPprPhos4ShapeMaker : public AthAlgorithm public: // These are the standard Athena public member functions. L1CaloPprPhos4ShapeMaker(const std::string& name, ISvcLocator* pSvcLocator); - virtual ~L1CaloPprPhos4ShapeMaker(){}; - virtual StatusCode initialize(); - virtual StatusCode execute(); - virtual StatusCode finalize(); + virtual StatusCode initialize() override; + virtual StatusCode execute() override; + virtual StatusCode finalize ATLAS_NOT_THREAD_SAFE() override; private: // Unless you provide a class with a default constructor, copy constructor and copy asignment operator diff --git a/Trigger/TrigT1/TrigT1CaloCalibUtils/src/L1CaloPprPhos4ShapeMaker.cxx b/Trigger/TrigT1/TrigT1CaloCalibUtils/src/L1CaloPprPhos4ShapeMaker.cxx index 5d2aafe4069..c4b152758cf 100644 --- a/Trigger/TrigT1/TrigT1CaloCalibUtils/src/L1CaloPprPhos4ShapeMaker.cxx +++ b/Trigger/TrigT1/TrigT1CaloCalibUtils/src/L1CaloPprPhos4ShapeMaker.cxx @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration */ #include "TrigT1CaloCalibUtils/L1CaloPprPhos4ShapeMaker.h" @@ -431,7 +431,7 @@ StatusCode L1CaloPprPhos4ShapeMaker::execute(){ return StatusCode::SUCCESS; } -StatusCode L1CaloPprPhos4ShapeMaker::finalize(){ +StatusCode L1CaloPprPhos4ShapeMaker::finalize ATLAS_NOT_THREAD_SAFE(){ // Place your post-event-loop code here ATH_MSG_INFO("In finalize()"); -- GitLab