Skip to content

Commit 9772aba

Browse files
committed
xrCore/XML/XMLDocument.cpp: adjust error logging
Now it's at least easier to find errors..
1 parent 145667f commit 9772aba

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/xrCore/XML/XMLDocument.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,8 @@ void XMLDocument::Load(pcstr path, pcstr xml_filename)
7474
{
7575
string1024 str;
7676
xr_sprintf(str, "XML Error! File: %s Description: %s:%u", m_xml_file_name, m_Doc.error(), m_Doc.errorOffset());
77-
R_ASSERT2(false, str);
77+
char* offsetted = (char*)W.pointer() + m_Doc.errorOffset();
78+
R_ASSERT3(false, str, offsetted ? offsetted : "wrong offset");
7879
}
7980

8081
m_root = m_Doc.firstChildElement();

0 commit comments

Comments
 (0)