Commit 752596b5 broke the build with -Werror
qemu/qemu_hotplug.c: In function 'qemuDomainChangeGraphics':
qemu/qemu_hotplug.c:1980:39: error: declaration of 'listen' shadows a
global declaration [-Werror=shadow]
Fix with s/listen/newlisten/
---
Pushing under the build-breaker rule.
src/qemu/qemu_hotplug.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/qemu/qemu_hotplug.c b/src/qemu/qemu_hotplug.c
index 637dbc5..18f5fa5 100644
--- a/src/qemu/qemu_hotplug.c
+++ b/src/qemu/qemu_hotplug.c
@@ -1977,18 +1977,18 @@ qemuDomainChangeGraphics(virQEMUDriverPtr driver,
}
for (i = 0; i < dev->nListens; i++) {
- virDomainGraphicsListenDefPtr listen = &dev->listens[i];
+ virDomainGraphicsListenDefPtr newlisten = &dev->listens[i];
virDomainGraphicsListenDefPtr oldlisten = &olddev->listens[i];
- if (listen->type != oldlisten->type) {
+ if (newlisten->type != oldlisten->type) {
virReportError(VIR_ERR_INVALID_ARG, "%s",
_("cannot change the type of listen address"));
goto cleanup;
}
- switch ((enum virDomainGraphicsListenType) listen->type) {
+ switch ((enum virDomainGraphicsListenType) newlisten->type) {
case VIR_DOMAIN_GRAPHICS_LISTEN_TYPE_ADDRESS:
- if (STRNEQ_NULLABLE(listen->address, oldlisten->address)) {
+ if (STRNEQ_NULLABLE(newlisten->address, oldlisten->address)) {
virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
dev->type == VIR_DOMAIN_GRAPHICS_TYPE_VNC ?
_("cannot change listen address setting on vnc
graphics") :
@@ -1998,7 +1998,7 @@ qemuDomainChangeGraphics(virQEMUDriverPtr driver,
break;
case VIR_DOMAIN_GRAPHICS_LISTEN_TYPE_NETWORK:
- if (STRNEQ_NULLABLE(listen->network, oldlisten->network)) {
+ if (STRNEQ_NULLABLE(newlisten->network, oldlisten->network)) {
virReportError(VIR_ERR_INVALID_ARG, "%s",
dev->type == VIR_DOMAIN_GRAPHICS_TYPE_VNC ?
_("cannot change listen network setting on vnc
graphics") :
--
1.7.7
Show replies by date