mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-10 17:35:59 +00:00
Now support ISO-style variable-argument macros, which is more portable than the gcc-specific variable-argument style ...
Original commit message from CVS: Now support ISO-style variable-argument macros, which is more portable than the gcc-specific variable-argument style of macros.
This commit is contained in:
parent
d5d8691718
commit
02a6f7ffa8
1 changed files with 14 additions and 1 deletions
|
@ -22,11 +22,24 @@ G_STMT_START{ \
|
|||
} \
|
||||
}G_STMT_END
|
||||
|
||||
#define PUT_STRING(pfx,str, a...) \
|
||||
#ifdef G_HAVE_ISO_VARARGS
|
||||
|
||||
#define PUT_STRING(pfx, ...) \
|
||||
G_STMT_START{ \
|
||||
gchar *ps_val = g_strdup_printf(__VA_ARGS__); \
|
||||
g_print ("%*.*s%s\n", pfx, pfx, "", ps_val); \
|
||||
g_free(ps_val); \
|
||||
}G_STMT_END
|
||||
|
||||
#elif defined(G_HAVE_GNUC_VARARGS)
|
||||
|
||||
#define PUT_STRING(pfx, str, a...) \
|
||||
G_STMT_START{ \
|
||||
g_print ("%*.*s"str"\n", pfx, pfx, "", ##a); \
|
||||
}G_STMT_END
|
||||
|
||||
#endif
|
||||
|
||||
static void
|
||||
print_prop (GstPropsEntry *prop, gint pfx)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue