[Mesa-dev] [PATCH 1/9] util/u_debug_flush: Use util_snprintf.
Brian Paul
brianp at vmware.com
Fri May 2 08:16:37 PDT 2014
On 05/02/2014 09:11 AM, jfonseca at vmware.com wrote:
> From: José Fonseca <jfonseca at vmware.com>
>
> ---
> src/gallium/auxiliary/util/u_debug_flush.c | 5 +++--
> 1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/src/gallium/auxiliary/util/u_debug_flush.c b/src/gallium/auxiliary/util/u_debug_flush.c
> index 9cf70db..fdb248c 100644
> --- a/src/gallium/auxiliary/util/u_debug_flush.c
> +++ b/src/gallium/auxiliary/util/u_debug_flush.c
> @@ -46,6 +46,7 @@
> #include "util/u_hash_table.h"
> #include "util/u_double_list.h"
> #include "util/u_inlines.h"
> +#include "util/u_string.h"
> #include "os/os_thread.h"
> #include <stdio.h>
>
> @@ -320,8 +321,8 @@ debug_flush_might_flush_cb(void *key, void *value, void *data)
> const char *reason = (const char *) data;
> char message[80];
>
> - snprintf(message, sizeof(message),
> - "%s referenced mapped buffer detected.", reason);
> + util_snprintf(message, sizeof(message),
> + "%s referenced mapped buffer detected.", reason);
>
> pipe_mutex_lock(fbuf->mutex);
> if (fbuf->mapped_sync) {
>
These all look good. I was about to send out the same 1/9 patch too.
I've got some other MSVC warning fixes that I'll post soon.
Reviewed-by: Brian Paul <brianp at vmware.com>
More information about the mesa-dev
mailing list