From 1cd49bf5e53c21fc1350019fc3f52b113378e5be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Guilloux?= Date: Thu, 15 Jun 2023 00:07:11 +0200 Subject: [PATCH] Fix ca1e34c: [Script] Wrong value printed for {RAW_STRING} (#11011) --- src/script/api/script_text.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/script/api/script_text.cpp b/src/script/api/script_text.cpp index cec2eb4a0d..4d13aa42b5 100644 --- a/src/script/api/script_text.cpp +++ b/src/script/api/script_text.cpp @@ -209,7 +209,7 @@ void ScriptText::_GetEncodedText(std::back_insert_iterator &output, switch (cur_param.type) { case StringParam::RAW_STRING: if (!std::holds_alternative(this->param[cur_idx])) throw Script_FatalError(fmt::format("{}: Parameter {} expects a raw string", name, param_count)); - fmt::format_to(output, ":\"%s\"", std::get(this->param[cur_idx++])); + fmt::format_to(output, ":\"{}\"", std::get(this->param[cur_idx++])); break; case StringParam::STRING: {