]> git.proxmox.com Git - mirror_qemu.git/commit - block/qapi.c
block: use GDateTime for formatting timestamp when dumping snapshot info
authorDaniel P. Berrangé <berrange@redhat.com>
Fri, 30 Apr 2021 11:59:06 +0000 (12:59 +0100)
committerDaniel P. Berrangé <berrange@redhat.com>
Mon, 14 Jun 2021 12:28:50 +0000 (13:28 +0100)
commit39683553f9a66b735a003ad43bb4d1460cef4d64
tree3e32ca7ee8c650049262308452a6067e547ae4f3
parent85cd1cc6687e827f3e5e94ad2e13444b75d0c5fa
block: use GDateTime for formatting timestamp when dumping snapshot info

The GDateTime APIs provided by GLib avoid portability pitfalls, such
as some platforms where 'struct timeval.tv_sec' field is still 'long'
instead of 'time_t'. When combined with automatic cleanup, GDateTime
often results in simpler code too.

Reviewed-by: Max Reitz <mreitz@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
block/qapi.c