kexec-tools/kexec-tools.gcc-bug.patch

28 lines
1.0 KiB
Diff

---
kexec/arch/i386/crashdump-x86.c | 2 ++
kexec/arch/x86_64/crashdump-x86_64.c | 2 ++
2 files changed, 4 insertions(+)
--- a/kexec/arch/i386/crashdump-x86.c
+++ b/kexec/arch/i386/crashdump-x86.c
@@ -286,6 +286,8 @@ static int delete_memmap(struct memory_r
unsigned long long mstart, mend;
struct memory_range temp_region;
+ /* kexec/arch/i386/crashdump-x86.c:343: warning: 'temp_region.type' is used uninitialized in this function */
+ memset(&temp_region, 0, sizeof(temp_region));
/* Do alignment check. */
if ((addr%align) || (size%align))
return -1;
--- a/kexec/arch/x86_64/crashdump-x86_64.c
+++ b/kexec/arch/x86_64/crashdump-x86_64.c
@@ -391,6 +391,8 @@ static int delete_memmap(struct memory_r
unsigned long long mstart, mend;
struct memory_range temp_region;
+ /* kexec/arch/x86_64/crashdump-x86_64.c:448: warning: 'temp_region.type' is used uninitialized in this function */
+ memset(&temp_region, 0, sizeof(temp_region));
/* Do alignment check. */
if ((addr%align) || (size%align))
return -1;