]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
Fix some missing parts in network code and schemas
authorDaniel Veillard <veillard@redhat.com>
Thu, 2 Jul 2009 14:02:18 +0000 (14:02 +0000)
committerDaniel Veillard <veillard@redhat.com>
Thu, 2 Jul 2009 14:02:18 +0000 (14:02 +0000)
* docs/schemas/network.rng: fix the network schemas to match
  new accepted elements, patch by Satoru SATOH
* src/network_conf.c: fix network driver to save the domain name
  in XML if present, patch by Satoru SATOH
* AUTHORS: adding Satoru SATOH
Daniel

AUTHORS
ChangeLog
docs/schemas/network.rng
src/network_conf.c

diff --git a/AUTHORS b/AUTHORS
index 4fbfb20e658744f628ea21f1544a626e4cfc62a8..dd537e6d7509d87ae91557fc358593980a1c6d10 100644 (file)
--- a/AUTHORS
+++ b/AUTHORS
@@ -76,6 +76,7 @@ Patches have also been contributed by:
   Federico Simoncelli  <federico.simoncelli@gmail.com>
   Amy Griffis          <amy.griffis@hp.com>
   Henrik Persson E     <henrik.e.persson@ericsson.com>
+  Satoru SATOH         <satoru.satoh@gmail.com>
 
   [....send patches to get your name here....]
 
index 129a2ccc7a6b27132fccd1d852e8aa1db5c3d157..3f89a74357be1cce3dc267ad1169ac041bac6a75 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+Thu Jul  2 15:58:09 CEST 2009 Daniel Veillard <veillard@redhat.com>
+
+       * docs/schemas/network.rng: fix the network schemas to match
+         new accepted elements, patch by Satoru SATOH
+       * src/network_conf.c: fix network driver to save the domain name
+         in XML if present, patch by Satoru SATOH
+       * AUTHORS: adding Satoru SATOH
+
 Wed Jul  1 23:29:33 CEST 2009 Daniel Veillard <veillard@redhat.com>
 
        * src/node_device.c: fix an endless loop in node device XML dump,
index 34c0163185feaa4bb28e7d3c0d667e293024dda4..a4281a52ffe58e8b049c3527335f94022ddac450 100644 (file)
@@ -1,6 +1,7 @@
 <!-- A Relax NG schema for the libvirt network XML format -->
 <element name="network" xmlns="http://relaxng.org/ns/structure/1.0"
          datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
+  <interleave>
   <!-- The name of the network, used to refer to it through the API
        and in virsh -->
   <element name="name"><text/></element>
       </optional>
     </element>
   </optional>
+  <optional>
+    <element name="domain">
+      <attribute name="name"><text/></attribute>
+    </element>
+  </optional>
   <optional>
     <!-- The IP element sets up NAT'ing and an optional DHCP server
          local to the host. -->
             <attribute name="end"><text/></attribute>
           </element>
         </zeroOrMore>
+        <zeroOrMore>
+          <element name="host">
+            <attribute name="mac"><text/></attribute>
+            <attribute name="name"><text/></attribute>
+            <attribute name="ip"><text/></attribute>
+          </element>
+        </zeroOrMore>
       </element>
     </element>
   </optional>
+  </interleave>
 </element>
index 1e0cbb8206b70b290b944230cecbd35a0d94203e..1b50b84e8a0ecb2d426ded9fe6de62cf405a5aa8 100644 (file)
@@ -592,6 +592,9 @@ char *virNetworkDefFormat(virConnectPtr conn,
                       def->stp ? "on" : "off",
                       def->delay);
 
+    if (def->domain)
+        virBufferVSprintf(&buf, "  <domain name='%s'/>\n", def->domain);
+
     if (def->ipAddress || def->netmask) {
         virBufferAddLit(&buf, "  <ip");