From: Jim Meyering Date: Fri, 30 Jan 2009 21:59:35 +0000 (+0000) Subject: tests: diagnose open failure X-Git-Tag: LIBVIRT_0_6_0~2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=cf1b0f868b7df01b6bb3760d912c44c4d4714ea3;p=thirdparty%2Flibvirt.git tests: diagnose open failure * tests/qemuxml2argvtest.c (testCompareXMLToArgvFiles): Diagnose failure to open an input file. --- diff --git a/ChangeLog b/ChangeLog index 5ca6eff364..ba141361dd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Fri Jan 30 22:57:34 +0100 2009 Jim Meyering + + tests: diagnose open failure + * tests/qemuxml2argvtest.c (testCompareXMLToArgvFiles): Diagnose + failure to open an input file. + Fri Jan 30 21:50:22 GMT 2009 Daniel P. Berrange * src/domain_conf.c: Fix empty decl in enum declaration diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c index 90b474018c..1d7aeb9d7a 100644 --- a/tests/qemuxml2argvtest.c +++ b/tests/qemuxml2argvtest.c @@ -36,8 +36,10 @@ static int testCompareXMLToArgvFiles(const char *xml, virDomainDefPtr vmdef = NULL; virDomainObj vm; - if (virtTestLoadFile(cmd, &expectargv, MAX_FILE) < 0) + if (virtTestLoadFile(cmd, &expectargv, MAX_FILE) < 0) { + fprintf(stderr, "failed to open %s: %s\n", cmd, strerror (errno)); goto fail; + } if (!(vmdef = virDomainDefParseFile(NULL, driver.caps, xml, VIR_DOMAIN_XML_INACTIVE)))