From c397f32066d6b58ac37cc68de780398e766a0966 Mon Sep 17 00:00:00 2001 From: falkTX Date: Sun, 23 Jan 2022 22:37:10 +0000 Subject: [PATCH] Correct the offset used in the custom data restore fix Signed-off-by: falkTX --- source/utils/CarlaStateUtils.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/utils/CarlaStateUtils.cpp b/source/utils/CarlaStateUtils.cpp index 22b89faf9..517989ce9 100644 --- a/source/utils/CarlaStateUtils.cpp +++ b/source/utils/CarlaStateUtils.cpp @@ -522,7 +522,7 @@ bool CarlaStateSave::fillFromXmlElement(const XmlElement* const xmlElement) if (std::strcmp(stateCustomData->type, CUSTOM_DATA_TYPE_CHUNK) == 0 || len >= 128+6) { CARLA_SAFE_ASSERT_CONTINUE(len >= 6); - cText = cText.substring(1, len - 6); + cText = cText.substring(1, len - 5); } stateCustomData->value = xmlSafeStringCharDup(cText, false);