Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 8 additions & 6 deletions core/meta/src/TClass.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -2677,8 +2677,10 @@ Int_t TClass::GetBaseClassOffsetRecurse(const TClass *cl)
Int_t off;
TBaseClass *inh;
TObjLink *lnk = 0;
if (fBase==0) lnk = GetListOfBases()->FirstLink();
else lnk = fBase.load()->FirstLink();
if (fBase.load() == 0)
lnk = GetListOfBases()->FirstLink();
else
lnk = fBase.load()->FirstLink();

// otherwise look at inheritance tree
while (lnk) {
Expand Down Expand Up @@ -3455,7 +3457,7 @@ const char *TClass::GetSharedLibs()

TList *TClass::GetListOfBases()
{
if (!fBase) {
if (!fBase.load()) {
if (fCanLoadClassInfo) {
if (fState == kHasTClassInit) {

Expand Down Expand Up @@ -3483,7 +3485,7 @@ TList *TClass::GetListOfBases()
Fatal("GetListOfBases", "gInterpreter not initialized");

R__LOCKGUARD(gInterpreterMutex);
if(!fBase) {
if (!fBase.load()) {
gInterpreter->CreateListOfBaseClasses(this);
}
}
Expand Down Expand Up @@ -3989,7 +3991,7 @@ void TClass::ResetCaches()

delete fAllPubData; fAllPubData = 0;

if (fBase)
if (fBase.load())
(*fBase).Delete();
delete fBase.load(); fBase = 0;

Expand Down Expand Up @@ -6460,7 +6462,7 @@ void TClass::StreamerDefault(const TClass* pThis, void *object, TBuffer &b, cons
// *and* before check fProperty, another thread might have call Property
// and this fProperty when we read it, is not -1 and fStreamerImpl is
// supposed to be set properly (no longer pointing to the default).
if (pThis->fStreamerImpl == &TClass::StreamerDefault) {
if (pThis->fStreamerImpl.load() == &TClass::StreamerDefault) {
pThis->Fatal("StreamerDefault", "fStreamerImpl not properly initialized (%d)", pThis->fStreamerType);
} else {
(*pThis->fStreamerImpl)(pThis,object,b,onfile_class);
Expand Down
7 changes: 3 additions & 4 deletions core/meta/src/TProtoClass.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -208,9 +208,8 @@ void TProtoClass::Delete(Option_t* opt /*= ""*/) {
/// duplicate dictionary is acceptable for namespace or STL collections.

Bool_t TProtoClass::FillTClass(TClass* cl) {
if (cl->fRealData || cl->fBase || cl->fData || cl->fEnums.load()
|| cl->fSizeof != -1 || cl->fCanSplit >= 0
|| cl->fProperty != (-1) ) {
if (cl->fRealData || cl->fBase.load() || cl->fData || cl->fEnums.load() || cl->fSizeof != -1 || cl->fCanSplit >= 0 ||
cl->fProperty != (-1)) {

if (cl->GetCollectionType() != ROOT::kNotSTL) {
// We are in the case of collection, duplicate dictionary are allowed
Expand Down Expand Up @@ -306,7 +305,7 @@ Bool_t TProtoClass::FillTClass(TClass* cl) {
cl->fStreamerType = fStreamerType;

// Update pointers to TClass
if (cl->fBase) {
if (cl->fBase.load()) {
for (auto base: *cl->fBase) {
((TBaseClass*)base)->SetClass(cl);
}
Expand Down