diff options
author | ydong10 <ydong10@6f19259b-4bc3-4df7-8a09-765794883524> | 2012-09-27 11:19:56 +0000 |
---|---|---|
committer | ydong10 <ydong10@6f19259b-4bc3-4df7-8a09-765794883524> | 2012-09-27 11:19:56 +0000 |
commit | 4706ff4fbc75010a22053cdf268e74ea16bc74ef (patch) | |
tree | f39d69f56a80e342411a6f901f5f5f40d06fb0ee /MdeModulePkg | |
parent | 18c4970711ac6e6f33b920f7d0b56f498da2c4e8 (diff) | |
download | edk2-platforms-4706ff4fbc75010a22053cdf268e74ea16bc74ef.tar.xz |
Enable EFI_IFR_DEFAULT2 opcode in browser.
Signed-off-by: Eric Dong <eric.dong@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13751 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdeModulePkg')
-rw-r--r-- | MdeModulePkg/Universal/SetupBrowserDxe/IfrParse.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/MdeModulePkg/Universal/SetupBrowserDxe/IfrParse.c b/MdeModulePkg/Universal/SetupBrowserDxe/IfrParse.c index 2cd666fc70..7221c42fa3 100644 --- a/MdeModulePkg/Universal/SetupBrowserDxe/IfrParse.c +++ b/MdeModulePkg/Universal/SetupBrowserDxe/IfrParse.c @@ -1779,8 +1779,10 @@ ParseOpCodes ( CurrentDefault->Value.Type = ((EFI_IFR_DEFAULT *) OpCodeData)->Type;
CopyMem (&CurrentDefault->DefaultId, &((EFI_IFR_DEFAULT *) OpCodeData)->DefaultId, sizeof (UINT16));
- CopyMem (&CurrentDefault->Value.Value, &((EFI_IFR_DEFAULT *) OpCodeData)->Value, sizeof (EFI_IFR_TYPE_VALUE));
- ExtendValueToU64 (&CurrentDefault->Value);
+ if (OpCodeLength == sizeof (EFI_IFR_DEFAULT)) {
+ CopyMem (&CurrentDefault->Value.Value, &((EFI_IFR_DEFAULT *) OpCodeData)->Value, sizeof (EFI_IFR_TYPE_VALUE));
+ ExtendValueToU64 (&CurrentDefault->Value);
+ }
//
// Insert to Default Value list of current Question
|