]> git.proxmox.com Git - mirror_edk2.git/commitdiff
MdePkg/BaseLib: Change a variable type in a bitwise operation
authorShenglei Zhang <shenglei.zhang@intel.com>
Thu, 14 Feb 2019 02:43:10 +0000 (10:43 +0800)
committerLiming Gao <liming.gao@intel.com>
Tue, 19 Feb 2019 08:15:15 +0000 (16:15 +0800)
Change the type of variable Chr from CHAR8 to UINT32 in a
bitwise operation, to make the two variables in the operation
have the same size.
https://bugzilla.tianocore.org/show_bug.cgi?id=1527

Cc: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Shenglei Zhang <shenglei.zhang@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
MdePkg/Library/BaseLib/String.c

index 53ff730e9e9ffde492a6d9336c31995418812d4c..a389115d719387d8b34679cdf8334ca2967251f7 100644 (file)
@@ -2070,7 +2070,7 @@ Base64Decode (
       Chr = DecodingTable[(UINT8) Source[SourceIndex++]];\r
       } while (Chr == BAD_V);\r
       Value <<= 6;\r
-      Value |= Chr;\r
+      Value |= (UINT32)Chr;\r
     }\r
 \r
     //\r