diff --git a/Trigger/TrigAnalysis/TrigEgammaAnalysisTools/src/TrigEgammaTDToolTest.cxx b/Trigger/TrigAnalysis/TrigEgammaAnalysisTools/src/TrigEgammaTDToolTest.cxx index ee47d297a68075ed8d4a5fd15c0be101a3fb1259..1b528ce06c122dc06077b71d898639ca5b18d82c 100644 --- a/Trigger/TrigAnalysis/TrigEgammaAnalysisTools/src/TrigEgammaTDToolTest.cxx +++ b/Trigger/TrigAnalysis/TrigEgammaAnalysisTools/src/TrigEgammaTDToolTest.cxx @@ -71,6 +71,7 @@ StatusCode TrigEgammaTDToolTest::execute() { const xAOD::ElectronContainer *onlElectrons = 0; if ( (evtStore()->retrieve(offElectrons,"Electrons")).isFailure() ){ ATH_MSG_ERROR("Failed to retrieve offline Electrons "); + return StatusCode::FAILURE; } ATH_MSG_INFO("Offline Electron container size " << offElectrons->size()); for(const auto eg : *offElectrons){ diff --git a/Trigger/TrigDataAccess/TrigSerializeTP/src/TrigSerTPTool.cxx b/Trigger/TrigDataAccess/TrigSerializeTP/src/TrigSerTPTool.cxx index 707e19750e07563b2f8257086a87f67bec46af91..fd074da83f5b1355bb2824b3930ebabd2c240241 100644 --- a/Trigger/TrigDataAccess/TrigSerializeTP/src/TrigSerTPTool.cxx +++ b/Trigger/TrigDataAccess/TrigSerializeTP/src/TrigSerTPTool.cxx @@ -108,6 +108,7 @@ void* TrigSerTPTool::convertTP( const std::string &clname, void *ptr, if( ! cnvtr ) { ATH_MSG_ERROR( "T/P Converter for transient class " << tpItr->first << " persistent class " << persName << " could not be retrieved"); + return nullptr; } // Create a persistent object: diff --git a/Trigger/TrigMonitoring/TrigBphysMonitoring/src/HLTXAODBphysMonTool.cxx b/Trigger/TrigMonitoring/TrigBphysMonitoring/src/HLTXAODBphysMonTool.cxx index 316972d80e9ec8f57dfa127b7185327d00c8bd5c..39334cb49962227fe20381b9532f188fc1465bc8 100644 --- a/Trigger/TrigMonitoring/TrigBphysMonitoring/src/HLTXAODBphysMonTool.cxx +++ b/Trigger/TrigMonitoring/TrigBphysMonitoring/src/HLTXAODBphysMonTool.cxx @@ -1816,6 +1816,7 @@ void HLTXAODBphysMonTool::fillTrigBphysHists(const xAOD::TrigBphys *bphysItem, c const std::string & prefix,const std::string & path, const std::string & chainName, const bool fullSetOfHists) { if (!bphysItem) { ATH_MSG_WARNING("fillTrigBphysHists null pointer provided"); + return; } ATH_MSG_DEBUG("fillTrigBphysHists for: " << bphysItem << " " << groupName << " " << prefix << " " <getRunNumber()); ATH_MSG_DEBUG( m_lumiBlocks.size() << " lumi blocks found"); for ( std::vector::const_iterator lbIt = m_lumiBlocks.begin(); diff --git a/Trigger/TrigT1/TrigT1CTP/src/CTPSimulation.cxx b/Trigger/TrigT1/TrigT1CTP/src/CTPSimulation.cxx index 1f5a641f75823ce33136d055b900fb5eec0c4d0c..f6356ed67ff00ef18e0799c36b37849b550ecc81 100644 --- a/Trigger/TrigT1/TrigT1CTP/src/CTPSimulation.cxx +++ b/Trigger/TrigT1/TrigT1CTP/src/CTPSimulation.cxx @@ -745,7 +745,7 @@ LVL1CTP::CTPSimulation::calculateJetMultiplicity( const TrigConf::L1Threshold & } else { ATH_MSG_ERROR( "Unexpected threshold name " << confThr.name() << ". Should start with j, jL, g, or J."); } - if(!rhk->empty()) { + if(rhk!=nullptr && !rhk->empty()) { auto jets = SG::makeHandle( *rhk, context ); if ( jets.isValid() ) { auto pt = confThr.getAttribute("pt"); diff --git a/Trigger/TrigT1/TrigT1CaloFexPerf/src/EFexEMClusterTool.cxx b/Trigger/TrigT1/TrigT1CaloFexPerf/src/EFexEMClusterTool.cxx index 134270a6582f7f1005f5712535ddb5ecdced84ae..567fdb751754658e05b4646deee33039ad4aafce 100644 --- a/Trigger/TrigT1/TrigT1CaloFexPerf/src/EFexEMClusterTool.cxx +++ b/Trigger/TrigT1/TrigT1CaloFexPerf/src/EFexEMClusterTool.cxx @@ -339,7 +339,7 @@ LVL1::EFexEMClusterTool::addOnce(const CaloCell* inputCell, std::vectorID() == oCell->ID()) alreadyThere=true; + else if (inputCell->ID() == oCell->ID()) alreadyThere=true; } if (!alreadyThere) outputVector.push_back(inputCell); } diff --git a/Trigger/TrigT1/TrigT1CaloMonitoring/src/JEPSimMon.cxx b/Trigger/TrigT1/TrigT1CaloMonitoring/src/JEPSimMon.cxx index b5a94290bf6959f4b5c96570960aeea4cd633faf..d47fb4f3a16f8643f30c7466daef9082074758db 100644 --- a/Trigger/TrigT1/TrigT1CaloMonitoring/src/JEPSimMon.cxx +++ b/Trigger/TrigT1/TrigT1CaloMonitoring/src/JEPSimMon.cxx @@ -695,7 +695,10 @@ StatusCode JEPSimMon::fillHistograms() { msg(MSG::DEBUG) << "No DAQ CMX RoIs found" << endmsg; } - cmxRoiTES = *cmxRoiTEScontainer->begin(); + else + { + cmxRoiTES = *cmxRoiTEScontainer->begin(); + } // Retrieve JEM Et Sums from SG const xAOD::JEMEtSumsContainer *jemEtSumsTES = 0; diff --git a/Trigger/TrigT1/TrigT1MuonRecRoiTool/src/TrigT1RPCRecRoiTool.cxx b/Trigger/TrigT1/TrigT1MuonRecRoiTool/src/TrigT1RPCRecRoiTool.cxx index 2400ec8e0dda72160dc065e23808e3ba074ff432..d5ca20871b309ee9da22024fb5caa397d6baa532 100644 --- a/Trigger/TrigT1/TrigT1MuonRecRoiTool/src/TrigT1RPCRecRoiTool.cxx +++ b/Trigger/TrigT1/TrigT1MuonRecRoiTool/src/TrigT1RPCRecRoiTool.cxx @@ -45,6 +45,10 @@ namespace LVL1 { SG::ReadCondHandle rpcReadHandle{m_rpcKey}; const RpcCablingCondData* rpcCab{*rpcReadHandle}; + if (rpcCab==nullptr){ + ATH_MSG_ERROR("Null pointer to the read RpcCablingCondData conditions object."); + return data; + } if(rpcCab->give_RoI_borders_id(data.side(), data.sector(), data.roi(), EtaLowBorder_id, EtaHighBorder_id, @@ -174,6 +178,10 @@ namespace LVL1 { SG::ReadCondHandle rpcReadHandle{m_rpcKey}; const RpcCablingCondData* rpcCab{*rpcReadHandle}; + if (rpcCab==nullptr){ + ATH_MSG_ERROR("Null pointer to the read RpcCablingCondData conditions object."); + return false; + } if(!rpcCab->give_LowPt_borders_id(data.side(), data.sector(), data.roi(), EtaLowBorder_id, EtaHighBorder_id, @@ -220,6 +228,10 @@ namespace LVL1 { SG::ReadCondHandle rpcReadHandle{m_rpcKey}; const RpcCablingCondData* rpcCab{*rpcReadHandle}; + if (rpcCab==nullptr){ + ATH_MSG_ERROR("Null pointer to the read RpcCablingCondData conditions object."); + return false; + } if(!rpcCab->give_HighPt_borders_id(data.side(), data.sector(), data.roi(), EtaLowBorder_id, EtaHighBorder_id,