diff options
Diffstat (limited to 'linden/indra/llcommon/llsdserialize_xml.cpp')
-rw-r--r-- | linden/indra/llcommon/llsdserialize_xml.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/linden/indra/llcommon/llsdserialize_xml.cpp b/linden/indra/llcommon/llsdserialize_xml.cpp index 04cdd57..85d3883 100644 --- a/linden/indra/llcommon/llsdserialize_xml.cpp +++ b/linden/indra/llcommon/llsdserialize_xml.cpp | |||
@@ -398,7 +398,10 @@ S32 LLSDXMLParser::Impl::parse(std::istream& input, LLSD& data) | |||
398 | status = XML_ParseBuffer(mParser, 0, true); | 398 | status = XML_ParseBuffer(mParser, 0, true); |
399 | if (status == XML_STATUS_ERROR && !mGracefullStop) | 399 | if (status == XML_STATUS_ERROR && !mGracefullStop) |
400 | { | 400 | { |
401 | ((char*) buffer)[count? count - 1 : 0] = '\0'; | 401 | if (buffer) |
402 | { | ||
403 | ((char*) buffer)[count ? count - 1 : 0] = '\0'; | ||
404 | } | ||
402 | llinfos << "LLSDXMLParser::Impl::parse: XML_STATUS_ERROR parsing:" << (char*) buffer << llendl; | 405 | llinfos << "LLSDXMLParser::Impl::parse: XML_STATUS_ERROR parsing:" << (char*) buffer << llendl; |
403 | data = LLSD(); | 406 | data = LLSD(); |
404 | return -1; | 407 | return -1; |