Re: [PATCH 2/2] virsh: fix snapshot-create-as to handle arbitrary names

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 08/10/2011 08:33 PM, Daniel Veillard wrote:
On Wed, Aug 10, 2011 at 05:02:37PM -0600, Eric Blake wrote:
Found this while revising the previous patch to use xpath rather
than strstr for undoing the escapse.

   typo, "escape"

I adjusted the message to fix that, then pushed this one first after all.

      virBufferAddLit(&buf, "<domainsnapshot>\n");
      if (name)
-        virBufferAsprintf(&buf, "<name>%s</name>\n", name);
+        virBufferEscapeString(&buf, "<name>%s</name>\n", name);
      if (desc)
-        virBufferAsprintf(&buf, "<description>%s</description>\n", desc);
+        virBufferEscapeString(&buf, "<description>%s</description>\n", desc);
      virBufferAddLit(&buf, "</domainsnapshot>\n");

      buffer = virBufferContentAndReset(&buf);

   Ah, right ! ACK

Pushed.

--
Eric Blake   eblake@xxxxxxxxxx    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]