[Mesa-dev] [PATCH V2 1/2] mesa: use PRId64/PRIu64 when printing 64-bit ints

Iago Toral itoral at igalia.com
Wed Feb 8 06:56:55 UTC 2017


Both patches are:

Reviewed-by: Iago Toral Quiroga <itoral at igalia.com>

On Wed, 2017-02-08 at 12:35 +1100, Timothy Arceri wrote:
> V2: actually use PRIu64
> ---
>  src/mesa/main/uniform_query.cpp | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/src/mesa/main/uniform_query.cpp
> b/src/mesa/main/uniform_query.cpp
> index 418cfc9..9da53a7 100644
> --- a/src/mesa/main/uniform_query.cpp
> +++ b/src/mesa/main/uniform_query.cpp
> @@ -563,10 +563,10 @@ log_uniform(const void *values, enum
> glsl_base_type basicType,
>  	 printf("%d ", v[i].i);
>  	 break;
>        case GLSL_TYPE_UINT64:
> -         printf("%lu ", *(uint64_t* )&v[i * 2].u);
> +         printf("%" PRIu64 " ", *(uint64_t* )&v[i * 2].u);
>           break;
>        case GLSL_TYPE_INT64:
> -         printf("%ld ", *(int64_t* )&v[i * 2].u);
> +         printf("%" PRId64 " ", *(int64_t* )&v[i * 2].u);
>           break;
>        case GLSL_TYPE_FLOAT:
>  	 printf("%g ", v[i].f);


More information about the mesa-dev mailing list