Skip to content

Commit

Permalink
xrCore/XML/XMLDocument.cpp: adjust error logging
Browse files Browse the repository at this point in the history
Now it's at least easier to find errors..
  • Loading branch information
Xottab-DUTY committed Jun 17, 2018
1 parent 145667f commit 9772aba
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/xrCore/XML/XMLDocument.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,8 @@ void XMLDocument::Load(pcstr path, pcstr xml_filename)
{
string1024 str;
xr_sprintf(str, "XML Error! File: %s Description: %s:%u", m_xml_file_name, m_Doc.error(), m_Doc.errorOffset());
R_ASSERT2(false, str);
char* offsetted = (char*)W.pointer() + m_Doc.errorOffset();
R_ASSERT3(false, str, offsetted ? offsetted : "wrong offset");
}

m_root = m_Doc.firstChildElement();
Expand Down

0 comments on commit 9772aba

Please sign in to comment.