From: "Daniel P. Berrange" <berrange(a)redhat.com>
The vshPrintRaw function is not used on Win32, and neither
is the 'msg' parameter of vshAskReedit. Change the nesting
of #ifdef WIN32 conditionals to address this
---
tools/virsh.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/tools/virsh.c b/tools/virsh.c
index 1b4f771..b84c4bc 100644
--- a/tools/virsh.c
+++ b/tools/virsh.c
@@ -655,6 +655,7 @@ vshReconnect(vshControl *ctl)
ctl->useSnapshotOld = false;
}
+#ifndef WIN32
static void
vshPrintRaw(vshControl *ctl, ...)
{
@@ -684,7 +685,6 @@ vshPrintRaw(vshControl *ctl, ...)
static int
vshAskReedit(vshControl *ctl, const char *msg)
{
-#ifndef WIN32
int c = -1;
struct termios ttyattr;
@@ -720,12 +720,16 @@ vshAskReedit(vshControl *ctl, const char *msg)
vshPrint(ctl, "\r\n");
return c;
+}
#else
+static int
+vshAskReedit(vshControl *ctl, const char *msg ATTRIBUTE_UNUSED)
+{
vshDebug(ctl, VSH_ERR_WARNING, "%s", _("This function is not "
"supported on WIN32 platform"));
return 0;
-#endif
}
+#endif
/* ---------------
* Commands
--
1.7.10.2