Commit 38b4fe1d authored by Philip Trettner's avatar Philip Trettner

Hopefully fixed threading problem with missing entry vector

parent 66757b37
......@@ -91,6 +91,16 @@ void ActionLabel::startEntry()
ActionEntry e;
e.labelIdx = mIndex;
writeTime(e);
if (!sEntries)
{
sLabelLock.lock();
if (!sEntries)
{
sEntries = new std::vector<ActionEntry>();
sEntriesPerThread.push_back(sEntries);
}
sLabelLock.unlock();
}
sEntries->push_back(e);
}
......
......@@ -49,6 +49,6 @@ public:
private:
ActionLabel(std::string const& name, std::string const& function, std::string const& file, int line, int idx);
friend class ActionPackage;
friend class ActionPackage;
};
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment