qemu: build failed due to unused variables

While compiling on F15 build crashed (probably because of new GCC).
This commit is contained in:
Peter Krempa 2011-07-13 12:11:43 +02:00 committed by Eric Blake
parent 64bd1b9dd5
commit 36caaddde6
2 changed files with 5 additions and 3 deletions

View File

@ -185,6 +185,7 @@ Patches have also been contributed by:
Michael Santos <michael.santos@gmail.com>
Alex Jia <ajia@redhat.com>
Oskari Saarenmaa <os@ohmu.fi>
Peter Krempa <pkrempa@redhat.com>
[....send patches to get your name here....]

View File

@ -1498,7 +1498,9 @@ static int qemuDomainReboot(virDomainPtr dom, unsigned int flags) {
struct qemud_driver *driver = dom->conn->privateData;
virDomainObjPtr vm;
int ret = -1;
#if HAVE_YAJL
qemuDomainObjPrivatePtr priv;
#endif
virCheckFlags(0, -1);
@ -1513,9 +1515,10 @@ static int qemuDomainReboot(virDomainPtr dom, unsigned int flags) {
_("no domain with matching uuid '%s'"), uuidstr);
goto cleanup;
}
priv = vm->privateData;
#if HAVE_YAJL
priv = vm->privateData;
if (qemuCapsGet(priv->qemuCaps, QEMU_CAPS_MONITOR_JSON)) {
if (qemuDomainObjBeginJob(driver, vm, QEMU_JOB_MODIFY) < 0)
goto cleanup;
@ -2598,7 +2601,6 @@ static int qemudDomainCoreDump(virDomainPtr dom,
int resume = 0, paused = 0;
int ret = -1;
virDomainEventPtr event = NULL;
qemuDomainObjPrivatePtr priv;
virCheckFlags(VIR_DUMP_LIVE | VIR_DUMP_CRASH, -1);
@ -2612,7 +2614,6 @@ static int qemudDomainCoreDump(virDomainPtr dom,
_("no domain with matching uuid '%s'"), uuidstr);
goto cleanup;
}
priv = vm->privateData;
if (qemuDomainObjBeginAsyncJobWithDriver(driver, vm,
QEMU_ASYNC_JOB_DUMP) < 0)