Serialize access to the debug journal

This commit is contained in:
Nik Bougalis
2016-05-19 00:39:19 -07:00
parent acebbf58eb
commit a039e7593a
13 changed files with 99 additions and 43 deletions

View File

@@ -76,7 +76,7 @@ STArray::STArray (SerialIter& sit, SField const& f)
if ((type == STI_OBJECT) && (field == 1))
{
JLOG (debugJournal().warn()) <<
JLOG (debugLog()) <<
"Encountered array with end of object marker";
Throw<std::runtime_error> ("Illegal terminator in array");
}
@@ -85,14 +85,14 @@ STArray::STArray (SerialIter& sit, SField const& f)
if (fn.isInvalid ())
{
JLOG (debugJournal().trace()) <<
JLOG (debugLog()) <<
"Unknown field: " << type << "/" << field;
Throw<std::runtime_error> ("Unknown field");
}
if (fn.fieldType != STI_OBJECT)
{
JLOG (debugJournal().trace()) <<
JLOG (debugLog()) <<
"Array contains non-object";
Throw<std::runtime_error> ("Non-object in array");
}