From: Roman Bogorodskiy Date: Sat, 9 May 2015 15:10:50 +0000 (+0300) Subject: bhyve: fix bhyvexml2argvtest build with gcc X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=846cc14c4d38169936a7165c4a4cb77b84d53bf6;p=people%2Fliuw%2Flibxenctrl-split%2Flibvirt.git bhyve: fix bhyvexml2argvtest build with gcc gcc5 reports an error like this: bhyvexml2argvtest.c: In function 'testCompareXMLToArgvFiles': bhyvexml2argvtest.c:24:18: error: variable 'vm' set but not used [-Werror=unused-but-set-variable] virDomainObj vm; ^ cc1: all warnings being treated as errors Fix by dropping this variable. --- diff --git a/tests/bhyvexml2argvtest.c b/tests/bhyvexml2argvtest.c index 1c7bc31a2..fa6f87f8c 100644 --- a/tests/bhyvexml2argvtest.c +++ b/tests/bhyvexml2argvtest.c @@ -21,7 +21,6 @@ static int testCompareXMLToArgvFiles(const char *xml, { char *actualargv = NULL, *actualld = NULL, *actualdm = NULL; virDomainDefPtr vmdef = NULL; - virDomainObj vm; virCommandPtr cmd = NULL, ldcmd = NULL; virConnectPtr conn; int ret = -1; @@ -33,7 +32,6 @@ static int testCompareXMLToArgvFiles(const char *xml, VIR_DOMAIN_DEF_PARSE_INACTIVE))) goto out; - vm.def = vmdef; conn->privateData = &driver; if (!(cmd = virBhyveProcessBuildBhyveCmd(conn, vmdef, false)))