aboutsummaryrefslogtreecommitdiff
path: root/qobject/qjson.c
diff options
context:
space:
mode:
Diffstat (limited to 'qobject/qjson.c')
-rw-r--r--qobject/qjson.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/qobject/qjson.c b/qobject/qjson.c
index e7100a539c..2f690c1816 100644
--- a/qobject/qjson.c
+++ b/qobject/qjson.c
@@ -284,15 +284,15 @@ static void to_json(const QObject *obj, GString *accu, bool pretty, int indent)
}
}
-QString *qobject_to_json_pretty(const QObject *obj, bool pretty)
+GString *qobject_to_json_pretty(const QObject *obj, bool pretty)
{
GString *accu = g_string_new(NULL);
to_json(obj, accu, pretty, 0);
- return qstring_from_gstring(accu);
+ return accu;
}
-QString *qobject_to_json(const QObject *obj)
+GString *qobject_to_json(const QObject *obj)
{
return qobject_to_json_pretty(obj, false);
}