]> git.proxmox.com Git - mirror_edk2.git/commitdiff
MdeModulePkg: Avoid update keyword string package.
authorEric Dong <eric.dong@intel.com>
Wed, 13 May 2015 08:36:49 +0000 (08:36 +0000)
committerydong10 <ydong10@Edk2>
Wed, 13 May 2015 08:36:49 +0000 (08:36 +0000)
When add new string, only update normal string package, avoid update keyword string package.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Eric Dong <eric.dong@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Samer El-Haj-Mahmoud <samer.el-haj-mahmoud@hp.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@17430 6f19259b-4bc3-4df7-8a09-765794883524

MdeModulePkg/Universal/HiiDatabaseDxe/String.c

index 1f4be0c40504a502477908e60d701bf6e03af255..7698cc27807097123223954f45fc8a8043ac23c8 100644 (file)
@@ -2,7 +2,7 @@
 Implementation for EFI_HII_STRING_PROTOCOL.\r
 \r
 \r
-Copyright (c) 2007 - 2014, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2007 - 2015, Intel Corporation. All rights reserved.<BR>\r
 This program and the accompanying materials\r
 are licensed and made available under the terms and conditions of the BSD License\r
 which accompanies this distribution.  The full text of the license may be found at\r
@@ -1834,6 +1834,12 @@ HiiGetLanguages (
        Link = Link->ForwardLink\r
       ) {\r
     StringPackage = CR (Link, HII_STRING_PACKAGE_INSTANCE, StringEntry, HII_STRING_PACKAGE_SIGNATURE);\r
+    if (AsciiStrnCmp (StringPackage->StringPkgHdr->Language, UEFI_CONFIG_LANG, AsciiStrLen (UEFI_CONFIG_LANG)) == 0) {\r
+      //\r
+      // Skip string package used for keyword protocol.\r
+      //\r
+      continue;\r
+    }\r
     ResultSize += AsciiStrSize (StringPackage->StringPkgHdr->Language);\r
     if (ResultSize <= *LanguagesSize) {\r
       AsciiStrCpy (Languages, StringPackage->StringPkgHdr->Language);\r