diff options
-rw-r--r-- | src/game/World.cpp | 2 | ||||
-rw-r--r-- | src/shared/Common.h | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/game/World.cpp b/src/game/World.cpp index 6b141057b86..b06f02e90b5 100644 --- a/src/game/World.cpp +++ b/src/game/World.cpp @@ -1724,7 +1724,7 @@ void World::DetectDBCLang() std::string availableLocalsStr; uint8 default_locale = MAX_LOCALE; - for (uint8 i = default_locale-1; i >= 0; --i) + for (uint8 i = default_locale-1; i < MAX_LOCALE; --i) // -1 will be 255 due to uint8 { if (strlen(race->name[i]) > 0) // check by race names { diff --git a/src/shared/Common.h b/src/shared/Common.h index be61019cef0..4a6aac43390 100644 --- a/src/shared/Common.h +++ b/src/shared/Common.h @@ -193,7 +193,7 @@ enum LocaleConstant LOCALE_ruRU = 8 }; -#define MAX_LOCALE 9 +const uint8 MAX_LOCALE = 9; extern char const* localeNames[MAX_LOCALE]; |