]> git.proxmox.com Git - mirror_edk2.git/commit
OvmfPkg/PlatformBootManagerLib: Fix gcc-4.8 Ia32 build failure
authorRuiyu Ni <ruiyu.ni@intel.com>
Tue, 3 May 2016 03:05:36 +0000 (11:05 +0800)
committerRuiyu Ni <ruiyu.ni@intel.com>
Wed, 4 May 2016 00:47:44 +0000 (08:47 +0800)
commit8e8fd303778822f21a9b6c6a5f59e8213a090fe4
treea3249cd80305126841a8f2f7b6c8701d71ff6001
parent817fb3ac2a781d4732d240ad69fb3fb9d44b0e29
OvmfPkg/PlatformBootManagerLib: Fix gcc-4.8 Ia32 build failure

The Width and Height assignment suppresses an invalid gcc-4.8 warning
on Ia32.
These warnings look unjustified to me. Namely, near the beginning of
the function, there is a while(1) loop. In that loop,
ConvertBmpToGopBlt() is called unconditionally. If the call fails,
the rest of the loop body is not reached (where the Height and Width
variables are used -- the compiler warns about their use in the
switch statement). If the call succeeds, then the variables are set.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Tested-by: Laszlo Ersek <lersek@redhat.com>
OvmfPkg/Library/PlatformBootManagerLib/QuietBoot.c