Index: src/qemu_conf.c =================================================================== RCS file: /data/cvs/libvirt/src/qemu_conf.c,v retrieving revision 1.21 diff -u -p -r1.21 qemu_conf.c --- src/qemu_conf.c 3 Dec 2007 14:30:47 -0000 1.21 +++ src/qemu_conf.c 4 Dec 2007 16:56:42 -0000 @@ -657,6 +657,11 @@ static int qemudParseInterfaceXML(virCon (net->type == QEMUD_NET_BRIDGE)) && xmlStrEqual(cur->name, BAD_CAST "target")) { ifname = xmlGetProp(cur, BAD_CAST "dev"); + if (STREQLEN("vnet", (const char*)ifname, 4)) { + /* An auto-generated target name, blank it out */ + xmlFree(ifname); + ifname = NULL; + } } else if ((script == NULL) && (net->type == QEMUD_NET_ETHERNET) && xmlStrEqual(cur->name, BAD_CAST "script")) { @@ -1411,6 +1416,7 @@ qemudNetworkIfaceConnect(virConnectPtr c } brname = network->bridge; if (net->dst.network.ifname[0] == '\0' || + STREQLEN(net->dst.network.ifname, "vnet", 4) || strchr(net->dst.network.ifname, '%')) { strcpy(net->dst.network.ifname, "vnet%d"); } @@ -1418,6 +1424,7 @@ qemudNetworkIfaceConnect(virConnectPtr c } else if (net->type == QEMUD_NET_BRIDGE) { brname = net->dst.bridge.brname; if (net->dst.bridge.ifname[0] == '\0' || + STREQLEN(net->dst.bridge.ifname, "vnet", 4) || strchr(net->dst.bridge.ifname, '%')) { strcpy(net->dst.bridge.ifname, "vnet%d"); }