diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c index f9022d43c2601e91bee4d21a5838bf739ccf7367..7d340eff024b18e068a22129772bd56bd001f6bc 100644 --- a/src/network/bridge_driver.c +++ b/src/network/bridge_driver.c @@ -1065,6 +1065,8 @@ networkDnsmasqConfContents(virNetworkObjPtr network, */ /* create dnsmasq config file appropriate for this network */ + + /* Don't forget to update networkxml2conftest :-) */ virBufferAsprintf(&configbuf, "##WARNING: THIS IS AN AUTO-GENERATED FILE. " "CHANGES TO IT ARE LIKELY TO BE\n" diff --git a/tests/networkxml2conftest.c b/tests/networkxml2conftest.c index a80d3b2d45d31f1542fc6e422168a6743872d5c2..7a976f42d8755d4dcf33ae82af5a2eee01f026ce 100644 --- a/tests/networkxml2conftest.c +++ b/tests/networkxml2conftest.c @@ -41,10 +41,22 @@ testCompareXMLToConfFiles(const char *inxml, const char *outconf, dnsmasqCapsPtr if (dctx == NULL) goto fail; - if (networkDnsmasqConfContents(obj, pidfile, &actual, - dctx, caps) < 0) + if (networkDnsmasqConfContents(obj, pidfile, &actual, dctx, caps) < 0) goto fail; + /* Any changes to this function ^^ should be reflected here too. */ +#ifndef __linux__ + char * tmp; + + if (!(tmp = virStringReplace(actual, + "except-interface=lo0\n", + "except-interface=lo\n"))) + goto fail; + VIR_FREE(actual); + actual = tmp; + tmp = NULL; +#endif + if (virTestCompareToFile(actual, outconf) < 0) goto fail;