7b49c0b
xl list -l should produce readable output when built with yajl2 so
7b49c0b
it is compatible with the xendomains script.
7b49c0b
7b49c0b
Signed-off-by: Michael Young <m.a.young@durham.ac.uk>
7b49c0b
7b49c0b
--- xen-4.2.2/tools/libxl/libxl_json.h.orig	2013-03-21 17:55:42.000000000 +0000
7b49c0b
+++ xen-4.2.2/tools/libxl/libxl_json.h	2013-04-10 22:14:15.938459238 +0100
7b49c0b
@@ -54,7 +54,11 @@
7b49c0b
 
7b49c0b
 static inline yajl_gen libxl_yajl_gen_alloc(const yajl_alloc_funcs *allocFuncs)
7b49c0b
 {
7b49c0b
-    return yajl_gen_alloc(allocFuncs);
7b49c0b
+    yajl_gen g;
7b49c0b
+    g = yajl_gen_alloc(allocFuncs);
7b49c0b
+    if (g)
7b49c0b
+        yajl_gen_config(g, yajl_gen_beautify, 1);
7b49c0b
+    return g;
7b49c0b
 }
7b49c0b
 
7b49c0b
 #else /* !HAVE_YAJL_V2 */