diff options
author | ydong10 <ydong10@6f19259b-4bc3-4df7-8a09-765794883524> | 2012-12-17 03:30:43 +0000 |
---|---|---|
committer | ydong10 <ydong10@6f19259b-4bc3-4df7-8a09-765794883524> | 2012-12-17 03:30:43 +0000 |
commit | 23fe74dc7633df5b5eca696b817c892aa4042beb (patch) | |
tree | e263347f9a4e5eb1d12f669a52b47363b5490845 /MdeModulePkg/Library | |
parent | d379cbc75d55fcebfbb86921c72194bb6cb3ca6e (diff) | |
download | edk2-platforms-23fe74dc7633df5b5eca696b817c892aa4042beb.tar.xz |
Base on the value type to get the value for default opcode.
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@14006 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdeModulePkg/Library')
-rw-r--r-- | MdeModulePkg/Library/UefiHiiLib/HiiLib.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/MdeModulePkg/Library/UefiHiiLib/HiiLib.c b/MdeModulePkg/Library/UefiHiiLib/HiiLib.c index 63c85dea2f..a2d31e7fda 100644 --- a/MdeModulePkg/Library/UefiHiiLib/HiiLib.c +++ b/MdeModulePkg/Library/UefiHiiLib/HiiLib.c @@ -2664,7 +2664,7 @@ HiiCreateDefaultOpCode ( OpCode.DefaultId = DefaultId;
CopyMem (&OpCode.Value, &Value, mHiiDefaultTypeToWidth[Type]);
- return InternalHiiCreateOpCode (OpCodeHandle, &OpCode, EFI_IFR_DEFAULT_OP, sizeof (OpCode));
+ return InternalHiiCreateOpCode (OpCodeHandle, &OpCode, EFI_IFR_DEFAULT_OP, OFFSET_OF(EFI_IFR_DEFAULT, Value) + mHiiDefaultTypeToWidth[Type]);
}
/**
|