Re: [Qemu-devel] [PATCH V10 15/17] block: dump to buffer for bdrv_image_info_dump()

2013-04-01 Thread Wenchao Xia
于 2013-4-2 3:17, Eric Blake 写道: On 03/22/2013 08:19 AM, Wenchao Xia wrote: This allow hmp use this function, just like qemu-img. It also returns a pointer now to make it easy to use. -void bdrv_image_info_dump(ImageInfo *info) +GCC_FMT_ATTR(3, 4) +static void snprintf_tail(char **p_buf,

Re: [Qemu-devel] [PATCH V10 15/17] block: dump to buffer for bdrv_image_info_dump()

2013-04-01 Thread Eric Blake
On 03/22/2013 08:19 AM, Wenchao Xia wrote: > This allow hmp use this function, just like qemu-img. > It also returns a pointer now to make it easy to use. > > > -void bdrv_image_info_dump(ImageInfo *info) > +GCC_FMT_ATTR(3, 4) > +static void snprintf_tail(char **p_buf, int *p_size, const char

[Qemu-devel] [PATCH V10 15/17] block: dump to buffer for bdrv_image_info_dump()

2013-03-22 Thread Wenchao Xia
This allow hmp use this function, just like qemu-img. It also returns a pointer now to make it easy to use. Signed-off-by: Wenchao Xia --- block/qapi.c | 67 +++-- include/block/qapi.h |2 +- qemu-img.c |6 +++- 3 files ch