diff options
author | Ruiyu Ni <ruiyu.ni@intel.com> | 2018-08-23 13:01:06 +0800 |
---|---|---|
committer | Ruiyu Ni <ruiyu.ni@intel.com> | 2018-08-27 15:20:47 +0800 |
commit | 47c04c382eb5c024173f8b8d37536ca25f9f93c4 (patch) | |
tree | f41ebdcb07fd675a0ce436fb8883bc6b296f1d97 /EmulatorPkg | |
parent | 983f5abb9a0d6cf9cfb5e16d671f15e5dc7510d8 (diff) | |
download | edk2-47c04c382eb5c024173f8b8d37536ca25f9f93c4.zip edk2-47c04c382eb5c024173f8b8d37536ca25f9f93c4.tar.gz edk2-47c04c382eb5c024173f8b8d37536ca25f9f93c4.tar.bz2 |
EmulatorPkg/ThunkProtocolList: Fix VS build failure
VS compiler complains converting UINTN to UINT16 causes data lost.
Add typecast to fix the build failure.
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Cc: Andrdw Fish <afish@apple.com>
Reviewed-by: Hao A Wu <hao.a.wu@intel.com>
Diffstat (limited to 'EmulatorPkg')
-rw-r--r-- | EmulatorPkg/Library/ThunkProtocolList/ThunkProtocolList.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/EmulatorPkg/Library/ThunkProtocolList/ThunkProtocolList.c b/EmulatorPkg/Library/ThunkProtocolList/ThunkProtocolList.c index b2daa2b..9fa9e25 100644 --- a/EmulatorPkg/Library/ThunkProtocolList/ThunkProtocolList.c +++ b/EmulatorPkg/Library/ThunkProtocolList/ThunkProtocolList.c @@ -2,7 +2,7 @@ Emulator Thunk to abstract OS services from pure EFI code
Copyright (c) 2008 - 2011, Apple Inc. All rights reserved.<BR>
- Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2011 - 2018, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
@@ -82,7 +82,7 @@ AddThunkProtocol ( Private->EmuBusDriver = EmuBusDriver;
CopyMem (&Private->Data, ThunkIo, sizeof (EMU_IO_THUNK_PROTOCOL));
- Private->Data.Instance = Instance++;
+ Private->Data.Instance = (UINT16)Instance++;
Private->Data.ConfigString = StartString;
InsertTailList (&mThunkList, &Private->Link);
|