Build: Fix analysis warnings

closes acidanthera/bugtracker#722
This commit is contained in:
vit9696 2020-02-16 15:46:12 +03:00
parent 5da113b944
commit 66979ff5c5
3 changed files with 9 additions and 7 deletions

View File

@ -1123,8 +1123,10 @@ InternalLoadBootEntry (
ZeroMem (DmgLoadContext, sizeof (*DmgLoadContext));
EntryData = NULL;
EntryDataSize = 0;
EntryData = NULL;
EntryDataSize = 0;
ParentDeviceHandle = NULL;
ParentFilePath = NULL;
if (BootEntry->IsFolder) {
if ((Context->LoadPolicy & OC_LOAD_ALLOW_DMG_BOOT) == 0) {
@ -1244,7 +1246,7 @@ InternalLoadBootEntry (
// fields to our custom device path, so we fix it up here.
// REF: https://github.com/acidanthera/bugtracker/issues/712
//
if (LoadedImage->DeviceHandle == NULL) {
if (LoadedImage->DeviceHandle == NULL && ParentDeviceHandle != NULL) {
if (LoadedImage->FilePath != NULL) {
FreePool (LoadedImage->FilePath);
}

View File

@ -189,7 +189,7 @@ DirectGopFromTarget (
ConfigureSize = 0;
Status = FrameBufferBltConfigure (
(VOID *) FramebufferBase,
(VOID *)(UINTN) FramebufferBase,
Info,
NULL,
&ConfigureSize
@ -204,7 +204,7 @@ DirectGopFromTarget (
}
Status = FrameBufferBltConfigure (
(VOID *) FramebufferBase,
(VOID *)(UINTN) FramebufferBase,
Info,
Context,
&ConfigureSize

View File

@ -461,10 +461,10 @@ InternalCalculateVMTFrequency (
// We get kHZ from node and we should translate it first.
//
if (FSBFrequency != NULL) {
*FSBFrequency = CpuidEbx * 1000;
*FSBFrequency = CpuidEbx * 1000ULL;
}
return CpuidEax * 1000;
return CpuidEax * 1000ULL;
}
UINT64