1
0
mirror of https://gitlab.com/libvirt/libvirt.git synced 2024-12-26 03:21:44 +03:00

Avoid compiler warnings in virCPUDefStealModel

Old GCC on CentOS 6 thinks vendor and vendor_id might be used
uninitialized in virCPUDefStealModel. The compiler is wrong, though.

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
This commit is contained in:
Jiri Denemark 2016-11-16 08:55:30 +01:00
parent 85fdcd5520
commit 29e17f65a8

View File

@ -144,8 +144,8 @@ virCPUDefStealModel(virCPUDefPtr dst,
virCPUDefPtr src,
bool keepVendor)
{
char *vendor;
char *vendor_id;
char *vendor = NULL;
char *vendor_id = NULL;
if (keepVendor) {
VIR_STEAL_PTR(vendor, dst->vendor);