[libvirt] [PATCH 02/21] util: Introduce virPrettySize
John Ferlan
jferlan at redhat.com
Mon Nov 13 18:36:58 UTC 2017
On 11/13/2017 03:50 AM, Martin Kletzander wrote:
> We can't output better memory sizes if we want to be compatible with libvirt
> older than the one which introduced /memory/unit, but for new things we can just
> output nicer capacity to the user if available. And this function enables that.
>
> Signed-off-by: Martin Kletzander <mkletzan at redhat.com>
> ---
> src/libvirt_private.syms | 1 +
> src/util/virutil.c | 50 ++++++++++++++++++++++++++++++++++++++++++++++++
> src/util/virutil.h | 3 +++
> 3 files changed, 54 insertions(+)
>
Since we have virFormatIntDecimal, why not change the name to be
virFormatPrettySize. I'd also support moving it closer to the virFormat*
function (both .c and .h), but it's not a "requirement"...
Reviewed-by: John Ferlan <jferlan at redhat.com>
John
More information about the libvir-list
mailing list