summaryrefslogtreecommitdiff
path: root/indra/llcommon/llsdutil.cpp
diff options
context:
space:
mode:
authorErik Kundiman <erik@megapahit.org>2024-07-20 21:54:19 +0800
committerErik Kundiman <erik@megapahit.org>2024-07-20 21:54:19 +0800
commit4cf12a6d223a238ff30f8b334ca91836c7369f88 (patch)
treea2bf8fa27e5fff8a1b8a75cdb5d835f4e959f145 /indra/llcommon/llsdutil.cpp
parent13f24f2419edeefbda8bedab01fad21cb97b7445 (diff)
parent569d97707459d5f87cb04a0811c0b7eb1b5c2251 (diff)
Merge branch 'main' into webrtc-voice
Diffstat (limited to 'indra/llcommon/llsdutil.cpp')
-rw-r--r--indra/llcommon/llsdutil.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/indra/llcommon/llsdutil.cpp b/indra/llcommon/llsdutil.cpp
index fb6b6bd589..09bfb51cc3 100644
--- a/indra/llcommon/llsdutil.cpp
+++ b/indra/llcommon/llsdutil.cpp
@@ -161,7 +161,7 @@ LLSD ll_binary_from_string(const LLSD& sd)
char* ll_print_sd(const LLSD& sd)
{
const U32 bufferSize = 10 * 1024;
- static char buffer[bufferSize];
+ static char buffer[bufferSize + 1];
std::ostringstream stream;
//stream.rdbuf()->pubsetbuf(buffer, bufferSize);
stream << LLSDOStreamer<LLSDXMLFormatter>(sd);
@@ -183,7 +183,7 @@ char* ll_pretty_print_sd_ptr(const LLSD* sd)
char* ll_pretty_print_sd(const LLSD& sd)
{
const U32 bufferSize = 100 * 1024;
- static char buffer[bufferSize];
+ static char buffer[bufferSize + 1];
std::ostringstream stream;
//stream.rdbuf()->pubsetbuf(buffer, bufferSize);
stream << LLSDOStreamer<LLSDXMLFormatter>(sd, LLSDFormatter::OPTIONS_PRETTY);