[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] Re: [PATCH 1/4] Add fprintf_function for function pointers
From: |
Blue Swirl |
Subject: |
[Qemu-devel] Re: [PATCH 1/4] Add fprintf_function for function pointers to fprintf-like functions |
Date: |
Sat, 30 Oct 2010 09:23:28 +0000 |
Thanks, applied all.
On Fri, Oct 22, 2010 at 9:03 PM, Stefan Weil <address@hidden> wrote:
> This kind of function pointers is used very often in qemu.
>
> The new data type uses format checking with GCC_FMT_ATTR
> and will be used in later patches.
>
> Cc: Blue Swirl <address@hidden>
> Signed-off-by: Stefan Weil <address@hidden>
> ---
> qemu-common.h | 3 +++
> 1 files changed, 3 insertions(+), 0 deletions(-)
>
> diff --git a/qemu-common.h b/qemu-common.h
> index d5ae420..7eeec8e 100644
> --- a/qemu-common.h
> +++ b/qemu-common.h
> @@ -81,6 +81,9 @@ struct iovec {
> #define GCC_FMT_ATTR(n, m)
> #endif
>
> +typedef int (*fprintf_function)(FILE *f, const char *fmt, ...)
> + GCC_FMT_ATTR(2, 3);
> +
> #ifdef _WIN32
> #define fsync _commit
> #define lseek _lseeki64
> --
> 1.7.1
>
>