Skip to content
  • Stefan Weil's avatar
    w32: Always use standard instead of native format strings · 95df51a4
    Stefan Weil authored
    
    
    GLib 2.0 include files use __printf__ for the format attribute
    which resolves to native format strings on w32 hosts.
    
    QEMU wants standard format strings instead of native format
    strings, so we simply change any declaration with __printf__
    to use __gnu_printf__.
    
    This works because all basic printf functions support both
    kinds of format strings.
    
    This fixes a compiler warning:
    
    qapi/string-output-visitor.c: In function ‘print_type_int’:
    qapi/string-output-visitor.c:34:5: warning: unknown conversion type character ‘l’ in format [-Wformat]
    qapi/string-output-visitor.c:34:5: warning: too many arguments for format [-Wformat-extra-args]
    
    Signed-off-by: default avatarStefan Weil <sw@weilnetz.de>
    Signed-off-by: default avatarStefan Hajnoczi <stefanha@gmail.com>
    95df51a4