Skip to content
Snippets Groups Projects
Commit bcf7c3d1 authored by Vakhtang Tsulaia's avatar Vakhtang Tsulaia
Browse files

Merge branch 'race.GeoModelKernel-20211013' into 'master'

GeoModelKernel: Fix race in RCBase::unref().

See merge request !95
parents ff0b07aa 22350614
No related branches found
No related tags found
1 merge request!95GeoModelKernel: Fix race in RCBase::unref().
/*
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
*/
#include "GeoModelKernel/RCBase.h"
......@@ -21,10 +21,7 @@ void RCBase::ref () const
void RCBase::unref () const
{
if (m_count.load()>0) {
m_count--;
if (m_count.load()==0) delete this;
}
if (--m_count == 0) delete this;
}
unsigned int RCBase::refCount () const
......
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