[libvirt] [PATCH] conf: fix build issue caused by shadowing global declaration

Pavel Hrdina posted 1 patch 6 years, 11 months ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/libvirt tags/patchew/065e89cf8bacd4a86bc1a1f0ee91ce086ed1202e.1495629177.git.phrdina@redhat.com
src/conf/domain_conf.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
[libvirt] [PATCH] conf: fix build issue caused by shadowing global declaration
Posted by Pavel Hrdina 6 years, 11 months ago
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
---

Pushed under build-breaker rule.

 src/conf/domain_conf.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
index 32234e8a54..d3c6e9c0ab 100644
--- a/src/conf/domain_conf.c
+++ b/src/conf/domain_conf.c
@@ -3525,12 +3525,12 @@ void virDomainDeviceInfoClear(virDomainDeviceInfoPtr info)
 
 static bool
 virDomainSkipBackcompatConsole(virDomainDefPtr def,
-                               size_t index,
+                               size_t idx,
                                bool all)
 {
-    virDomainChrDefPtr console = def->consoles[index];
+    virDomainChrDefPtr console = def->consoles[idx];
 
-    if (!all && index == 0 &&
+    if (!all && idx == 0 &&
         (console->targetType == VIR_DOMAIN_CHR_CONSOLE_TARGET_TYPE_SERIAL ||
          console->targetType == VIR_DOMAIN_CHR_CONSOLE_TARGET_TYPE_NONE) &&
         def->os.type == VIR_DOMAIN_OSTYPE_HVM) {
-- 
2.13.0

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list