1
0
mirror of https://github.com/godotengine/godot.git synced 2025-12-07 17:36:07 +00:00

[TextServer] Ensure ICU data is initialised only one and cleaned only at exit.

(cherry picked from commit 7f24433e15)
This commit is contained in:
bruvzg
2023-02-21 09:43:54 +02:00
committed by Yuri Sizov
parent e290448fe3
commit 466d226a4a
2 changed files with 5 additions and 2 deletions

View File

@@ -334,6 +334,8 @@ _FORCE_INLINE_ bool is_connected_to_prev(char32_t p_chr, char32_t p_pchr) {
/*************************************************************************/
bool TextServerAdvanced::icu_data_loaded = false;
bool TextServerAdvanced::_has_feature(Feature p_feature) const {
switch (p_feature) {
case FEATURE_SIMPLE_LAYOUT:
@@ -6599,5 +6601,6 @@ TextServerAdvanced::~TextServerAdvanced() {
uset_close(allowed);
allowed = nullptr;
}
u_cleanup();
std::atexit(u_cleanup);
}