From: Eric Engestrom Date: Tue, 20 Nov 2018 11:55:55 +0000 (+0000) Subject: util: use standard name for vasprintf() X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=00e23cd96998deae429508efa10545be13420379;p=mesa.git util: use standard name for vasprintf() Signed-off-by: Eric Engestrom Reviewed-by: Eric Anholt Reviewed-by: Emil Velikov Reviewed-by: Eric Anholt --- diff --git a/src/gallium/auxiliary/util/u_async_debug.c b/src/gallium/auxiliary/util/u_async_debug.c index 04faa6850e7..d7aefbfe46b 100644 --- a/src/gallium/auxiliary/util/u_async_debug.c +++ b/src/gallium/auxiliary/util/u_async_debug.c @@ -40,7 +40,7 @@ u_async_debug_message(void *data, unsigned *id, enum pipe_debug_type type, char *text; int r; - r = util_vasprintf(&text, fmt, args); + r = vasprintf(&text, fmt, args); if (r < 0) return; diff --git a/src/gallium/auxiliary/util/u_log.c b/src/gallium/auxiliary/util/u_log.c index 095421edd06..4e261500a03 100644 --- a/src/gallium/auxiliary/util/u_log.c +++ b/src/gallium/auxiliary/util/u_log.c @@ -130,7 +130,7 @@ u_log_printf(struct u_log_context *ctx, const char *fmt, ...) char *str = NULL; va_start(va, fmt); - int ret = util_vasprintf(&str, fmt, va); + int ret = vasprintf(&str, fmt, va); va_end(va); if (ret >= 0) { diff --git a/src/util/u_string.h b/src/util/u_string.h index d91293c3380..846b64feb11 100644 --- a/src/util/u_string.h +++ b/src/util/u_string.h @@ -105,6 +105,7 @@ util_sprintf(char *str, const char *format, ...) va_end(ap); } +#define vasprintf util_vasprintf static inline int util_vasprintf(char **ret, const char *format, va_list ap) { @@ -184,7 +185,6 @@ util_strncmp(const char *s1, const char *s2, size_t n) #define util_vsnprintf vsnprintf #define util_snprintf snprintf -#define util_vasprintf vasprintf #endif