summaryrefslogtreecommitdiff
path: root/src/script/api/script_basestation.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2013-06-27 19:57:41 +0000
committerrubidium <rubidium@openttd.org>2013-06-27 19:57:41 +0000
commit19eca468fcfbd8f15cd61cfd54a6971c0cbd3039 (patch)
tree933e198011751ed6862511f3835453e49307a835 /src/script/api/script_basestation.cpp
parent8463335b009a95636a40dbd5b3f7400a98b76870 (diff)
downloadopenttd-19eca468fcfbd8f15cd61cfd54a6971c0cbd3039.tar.xz
(svn r25488) -Fix [FS#5613]: do not send encoded texts to names, but decode them into a plain C string and then pass them on
Diffstat (limited to 'src/script/api/script_basestation.cpp')
-rw-r--r--src/script/api/script_basestation.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/script/api/script_basestation.cpp b/src/script/api/script_basestation.cpp
index 981ec2c31..d46d717a0 100644
--- a/src/script/api/script_basestation.cpp
+++ b/src/script/api/script_basestation.cpp
@@ -38,7 +38,7 @@
EnforcePrecondition(false, ScriptObject::GetCompany() != OWNER_DEITY);
EnforcePrecondition(false, IsValidBaseStation(station_id));
EnforcePrecondition(false, name != NULL);
- const char *text = name->GetEncodedText();
+ const char *text = name->GetDecodedText();
EnforcePreconditionEncodedText(false, text);
EnforcePreconditionCustomError(false, ::Utf8StringLength(text) < MAX_LENGTH_STATION_NAME_CHARS, ScriptError::ERR_PRECONDITION_STRING_TOO_LONG);