mirror of
https://github.com/libvirt/libvirt.git
synced 2025-02-25 18:55:26 -06:00
Fix unused parameters / functions in virsh on Win32
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 Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
This commit is contained in:
@@ -649,6 +649,7 @@ vshReconnect(vshControl *ctl)
|
|||||||
ctl->useSnapshotOld = false;
|
ctl->useSnapshotOld = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifndef WIN32
|
||||||
static void
|
static void
|
||||||
vshPrintRaw(vshControl *ctl, ...)
|
vshPrintRaw(vshControl *ctl, ...)
|
||||||
{
|
{
|
||||||
@@ -678,7 +679,6 @@ vshPrintRaw(vshControl *ctl, ...)
|
|||||||
static int
|
static int
|
||||||
vshAskReedit(vshControl *ctl, const char *msg)
|
vshAskReedit(vshControl *ctl, const char *msg)
|
||||||
{
|
{
|
||||||
#ifndef WIN32
|
|
||||||
int c = -1;
|
int c = -1;
|
||||||
struct termios ttyattr;
|
struct termios ttyattr;
|
||||||
|
|
||||||
@@ -714,12 +714,16 @@ vshAskReedit(vshControl *ctl, const char *msg)
|
|||||||
|
|
||||||
vshPrint(ctl, "\r\n");
|
vshPrint(ctl, "\r\n");
|
||||||
return c;
|
return c;
|
||||||
#else
|
}
|
||||||
|
#else /* WIN32 */
|
||||||
|
static int
|
||||||
|
vshAskReedit(vshControl *ctl, const char *msg ATTRIBUTE_UNUSED)
|
||||||
|
{
|
||||||
vshDebug(ctl, VSH_ERR_WARNING, "%s", _("This function is not "
|
vshDebug(ctl, VSH_ERR_WARNING, "%s", _("This function is not "
|
||||||
"supported on WIN32 platform"));
|
"supported on WIN32 platform"));
|
||||||
return 0;
|
return 0;
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
#endif /* WIN32 */
|
||||||
|
|
||||||
/* ---------------
|
/* ---------------
|
||||||
* Commands
|
* Commands
|
||||||
|
|||||||
Reference in New Issue
Block a user