浏览代码

[acpi] Fix spurious uninitialised-variable warning on some gcc versions

Reported-by: Christian Nilsson <nikize@gmail.com>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
tags/v1.20.1
Michael Brown 8 年前
父节点
当前提交
51a79731f6
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1
    1
      src/core/acpi.c

+ 1
- 1
src/core/acpi.c 查看文件

51
 static uint8_t acpi_checksum ( userptr_t table ) {
51
 static uint8_t acpi_checksum ( userptr_t table ) {
52
 	struct acpi_header acpi;
52
 	struct acpi_header acpi;
53
 	uint8_t sum = 0;
53
 	uint8_t sum = 0;
54
-	uint8_t data;
54
+	uint8_t data = 0;
55
 	unsigned int i;
55
 	unsigned int i;
56
 
56
 
57
 	/* Read table length */
57
 	/* Read table length */

正在加载...
取消
保存