Skip to content
Snippets Groups Projects
Commit e21141c1 authored by Adam Edward Barton's avatar Adam Edward Barton
Browse files

fix unchecked status code in IDC

parent eefc26bf
No related branches found
No related tags found
No related merge requests found
...@@ -92,13 +92,15 @@ public: ...@@ -92,13 +92,15 @@ public:
return StatusCode::SUCCESS; return StatusCode::SUCCESS;
} }
void MergeToRealContainer(IIdentifiableCont<T> *real){ StatusCode MergeToRealContainer(IIdentifiableCont<T> *real){
for(auto &x : m_usedhashes){ for(auto &x : m_usedhashes){
auto ptr = std::unique_ptr<T>(const_cast<T*>( x.second)); auto ptr = std::unique_ptr<T>(const_cast<T*>( x.second));
real->addOrDelete(std::move(ptr), x.first); auto sc = real->addOrDelete(std::move(ptr), x.first);
if(sc.isFailure()) { return StatusCode::FAILURE; }
m_randomcont[x.first] = nullptr; m_randomcont[x.first] = nullptr;
} }
m_usedhashes.clear(); m_usedhashes.clear();
return StatusCode::SUCCESS;
} }
virtual void cleanup() override{ virtual void cleanup() override{
......
...@@ -156,7 +156,7 @@ StatusCode PixelRawDataProvider::execute() { ...@@ -156,7 +156,7 @@ StatusCode PixelRawDataProvider::execute() {
if (m_rawDataTool->convert(listOfRobf, containerInterface).isFailure()) if (m_rawDataTool->convert(listOfRobf, containerInterface).isFailure())
ATH_MSG_ERROR("BS conversion into RDOs failed"); ATH_MSG_ERROR("BS conversion into RDOs failed");
if(tempcont) tempcont->MergeToRealContainer(rdoContainer.ptr()); if(tempcont) ATH_CHECK(tempcont->MergeToRealContainer(rdoContainer.ptr()));
#ifdef PIXEL_DEBUG #ifdef PIXEL_DEBUG
ATH_MSG_DEBUG("Number of Collections in IDC " << rdoContainer->numberOfCollections()); ATH_MSG_DEBUG("Number of Collections in IDC " << rdoContainer->numberOfCollections());
#endif #endif
......
...@@ -156,7 +156,7 @@ StatusCode SCTRawDataProvider::execute() ...@@ -156,7 +156,7 @@ StatusCode SCTRawDataProvider::execute()
ATH_MSG_WARNING("BS conversion into RDOs failed"); ATH_MSG_WARNING("BS conversion into RDOs failed");
} }
if (dummyRDO) dummyRDO->MergeToRealContainer(rdoContainer.ptr()); if (dummyRDO) ATH_CHECK(dummyRDO->MergeToRealContainer(rdoContainer.ptr()));
return StatusCode::SUCCESS; return StatusCode::SUCCESS;
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment