[PATCH 3/4] xend: urlencode: Properly escape '&'

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

 



Since we send the sexpr to xend via HTTP, we need to properly escape
'&'

Signed-off-by: Cole Robinson <crobinso@xxxxxxxxxx>
---
 src/xen/xend_internal.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/src/xen/xend_internal.c b/src/xen/xend_internal.c
index d6d66bd..3ccadde 100644
--- a/src/xen/xend_internal.c
+++ b/src/xen/xend_internal.c
@@ -710,6 +710,7 @@ urlencode(const char *string)
         switch (string[i]) {
             case ' ':
             case '\n':
+            case '&':
                 snprintf(ptr, 4, "%%%02x", string[i]);
                 ptr += 3;
                 break;
-- 
1.7.3.2

--
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]