summaryrefslogtreecommitdiff
path: root/IntelFrameworkModulePkg
diff options
context:
space:
mode:
authorydong10 <ydong10@6f19259b-4bc3-4df7-8a09-765794883524>2011-09-06 07:05:06 +0000
committerydong10 <ydong10@6f19259b-4bc3-4df7-8a09-765794883524>2011-09-06 07:05:06 +0000
commita3b4eb29330f688aba823d8669a408c97a551699 (patch)
treeab5df0c40b4f2bb8e04b885525edd1565030b6ee /IntelFrameworkModulePkg
parent5c4513344acd84ac066545ed4c6579f4de091218 (diff)
downloadedk2-a3b4eb29330f688aba823d8669a408c97a551699.zip
edk2-a3b4eb29330f688aba823d8669a408c97a551699.tar.gz
edk2-a3b4eb29330f688aba823d8669a408c97a551699.tar.bz2
Check the pointer before use it.
Signed-off-by:ydong10 Reviewed-by:vanjeff git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12283 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'IntelFrameworkModulePkg')
-rw-r--r--IntelFrameworkModulePkg/Universal/Acpi/AcpiSupportDxe/AcpiSupportAcpiSupportProtocol.c23
1 files changed, 12 insertions, 11 deletions
diff --git a/IntelFrameworkModulePkg/Universal/Acpi/AcpiSupportDxe/AcpiSupportAcpiSupportProtocol.c b/IntelFrameworkModulePkg/Universal/Acpi/AcpiSupportDxe/AcpiSupportAcpiSupportProtocol.c
index 1a28f02..6c9cb74 100644
--- a/IntelFrameworkModulePkg/Universal/Acpi/AcpiSupportDxe/AcpiSupportAcpiSupportProtocol.c
+++ b/IntelFrameworkModulePkg/Universal/Acpi/AcpiSupportDxe/AcpiSupportAcpiSupportProtocol.c
@@ -844,17 +844,18 @@ AddTableToList (
);
AcpiSupportInstance->Xsdt->OemRevision = AcpiSupportInstance->Fadt3->Header.OemRevision;
}
- }
- //
- // Checksum the table
- //
- if (Checksum) {
- AcpiPlatformChecksum (
- CurrentTableList->Table,
- CurrentTableList->Table->Length,
- OFFSET_OF (EFI_ACPI_DESCRIPTION_HEADER,
- Checksum)
- );
+
+ //
+ // Checksum the table
+ //
+ if (Checksum) {
+ AcpiPlatformChecksum (
+ CurrentTableList->Table,
+ CurrentTableList->Table->Length,
+ OFFSET_OF (EFI_ACPI_DESCRIPTION_HEADER,
+ Checksum)
+ );
+ }
}
break;