The json parser does not support "%I64d", so we have to use "%lld" instead of "%I64d".
Signed-off-by: TeLeMan <gele...@gmail.com> --- migration.c | 6 +++--- monitor.c | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/migration.c b/migration.c index f20315f..f44b857 100644 --- a/migration.c +++ b/migration.c @@ -180,9 +180,9 @@ static void migrate_put_status(QDict *qdict, const char *name, { QObject *obj; - obj = qobject_from_jsonf("{ 'transferred': %" PRId64 ", " - "'remaining': %" PRId64 ", " - "'total': %" PRId64 " }", trans, rem, total); + obj = qobject_from_jsonf("{ 'transferred': %lld, " + "'remaining': %lld, " + "'total': %lld }", trans, rem, total); assert(obj != NULL); qdict_put_obj(qdict, name, obj); diff --git a/monitor.c b/monitor.c index a86454b..1738d2a 100644 --- a/monitor.c +++ b/monitor.c @@ -342,8 +342,8 @@ static void timestamp_put(QDict *qdict) if (err < 0) return; - obj = qobject_from_jsonf("{ 'seconds': %" PRId64 ", " - "'microseconds': %" PRId64 " }", + obj = qobject_from_jsonf("{ 'seconds': %lld, " + "'microseconds': %lld }", (int64_t) tv.tv_sec, (int64_t) tv.tv_usec); assert(obj != NULL); -- 1.6.5.1.1367.gcd48 -- SUN OF A BEACH