REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2300
On some firmwares PlatformLang is set to the local language (e.g. ru-RU),
however there is no Unicode Collation protocol instance that supports it.
As for missing PlatformLang, fall back to the first found instance.
Cc: Ray Ni <ray.ni@intel.com>
Cc: Zhichao Gao <zhichao.gao@intel.com>
Reviewed-by: Zhichao Gao <zhichao.gao@intel.com>
Signed-off-by: Marvin Haeuser <mhaeuser@outlook.de>
\r
//\r
// Without clue provided use the first Unicode Collation2 protocol.\r
+ // This may happen when PlatformLang is NULL or when no installed Unicode\r
+ // Collation2 protocol instance supports PlatformLang.\r
//\r
- if (PlatformLang == NULL) {\r
+ if (gUnicodeCollation == NULL) {\r
gUnicodeCollation = Uc;\r
+ }\r
+ if (PlatformLang == NULL) {\r
break;\r
}\r
\r