[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 19/20] target/i386/cpu: Fix memleak in x86_cpu_class_check_missing
From: |
Eduardo Habkost |
Subject: |
[PULL 19/20] target/i386/cpu: Fix memleak in x86_cpu_class_check_missing_features |
Date: |
Wed, 2 Sep 2020 07:53:22 -0400 |
From: Pan Nengyuan <pannengyuan@huawei.com>
'err' forgot to free in x86_cpu_class_check_missing_features error path.
Fix that.
Reported-by: Euler Robot <euler.robot@huawei.com>
Signed-off-by: Pan Nengyuan <pannengyuan@huawei.com>
Reviewed-by: Li Qiang <liq3ea@gmail.com>
Reviewed-by: Markus Armbruster <armbru@redhat.com>
Message-Id: <20200831134315.1221-7-pannengyuan@huawei.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
target/i386/cpu.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/target/i386/cpu.c b/target/i386/cpu.c
index ba4667b33c..49d8958528 100644
--- a/target/i386/cpu.c
+++ b/target/i386/cpu.c
@@ -4947,6 +4947,7 @@ static void
x86_cpu_class_check_missing_features(X86CPUClass *xcc,
new->value = g_strdup("type");
*next = new;
next = &new->next;
+ error_free(err);
}
x86_cpu_filter_features(xc, false);
--
2.26.2
- [PULL 09/20] tls-cipher-suites: Correct instance_size, (continued)
- [PULL 09/20] tls-cipher-suites: Correct instance_size, Eduardo Habkost, 2020/09/02
- [PULL 11/20] Revert "target/i386: Enable new apic id encoding for EPYC based cpus models", Eduardo Habkost, 2020/09/02
- [PULL 12/20] Revert "hw/i386: Move arch_id decode inside x86_cpus_init", Eduardo Habkost, 2020/09/02
- [PULL 10/20] Revert "i386: Fix pkg_id offset for EPYC cpu models", Eduardo Habkost, 2020/09/02
- [PULL 14/20] Revert "hw/i386: Introduce apicid functions inside X86MachineState", Eduardo Habkost, 2020/09/02
- [PULL 13/20] Revert "i386: Introduce use_epyc_apic_id_encoding in X86CPUDefinition", Eduardo Habkost, 2020/09/02
- [PULL 16/20] Revert "hw/386: Add EPYC mode topology decoding functions", Eduardo Habkost, 2020/09/02
- [PULL 17/20] Revert "hw/i386: Update structures to save the number of nodes per package", Eduardo Habkost, 2020/09/02
- [PULL 15/20] Revert "target/i386: Cleanup and use the EPYC mode topology functions", Eduardo Habkost, 2020/09/02
- [PULL 18/20] virtio: add Virtio*BusClass sizes, Eduardo Habkost, 2020/09/02
- [PULL 19/20] target/i386/cpu: Fix memleak in x86_cpu_class_check_missing_features,
Eduardo Habkost <=
- [PULL 20/20] target/i386/sev: Plug memleak in sev_read_file_base64, Eduardo Habkost, 2020/09/02
- Re: [PULL 00/20] x86 and machine queue, 2020-09-02, Peter Maydell, 2020/09/02