[libvirt] [PATCH] forbid autostart on transcient networks
Daniel Veillard
veillard at redhat.com
Wed Jun 3 13:27:08 UTC 2009
As the operation doesn't make sense, really,
Daniel
--
Daniel Veillard | libxml Gnome XML XSLT toolkit http://xmlsoft.org/
daniel at veillard.com | Rpmfind RPM search engine http://rpmfind.net/
http://veillard.com/ | virtualization library http://libvirt.org/
-------------- next part --------------
Index: src/network_driver.c
===================================================================
RCS file: /data/cvs/libxen/src/network_driver.c,v
retrieving revision 1.28
diff -u -r1.28 network_driver.c
--- src/network_driver.c 29 May 2009 14:18:57 -0000 1.28
+++ src/network_driver.c 3 Jun 2009 13:25:23 -0000
@@ -1353,6 +1353,12 @@
goto cleanup;
}
+ if (!network->persistent) {
+ networkReportError(net->conn, NULL, net, VIR_ERR_INTERNAL_ERROR,
+ "%s", _("cannot set autostart for transient network"));
+ goto cleanup;
+ }
+
autostart = (autostart != 0);
if (network->autostart != autostart) {
More information about the libvir-list
mailing list