Re: [Mesa-dev] [PATCH 1/5] gallium/util: add a helper util_create_shader_from_text, cleanup some code

2014-12-12 Thread Marek Olšák
Alternatively, I can search the format string and reject it if it contains '%' not followed by 's'. Marek On Wed, Dec 10, 2014 at 9:37 PM, Marek Olšák mar...@gmail.com wrote: Indeed, locales can cause problems. Would vsnprintf_l that overrides the current locale or uselocale address your

Re: [Mesa-dev] [PATCH 1/5] gallium/util: add a helper util_create_shader_from_text, cleanup some code

2014-12-10 Thread Jose Fonseca
On 09/12/14 11:28, Marek Olšák wrote: From: Marek Olšák marek.ol...@amd.com It's exposed, because I plan to use it elsewhere later. I hesitate in repeating myself, but I can't close my eyes. This is such a bad idea, at so many levels. How will this cope when the application is running on

Re: [Mesa-dev] [PATCH 1/5] gallium/util: add a helper util_create_shader_from_text, cleanup some code

2014-12-10 Thread Marek Olšák
Indeed, locales can cause problems. Would vsnprintf_l that overrides the current locale or uselocale address your concerns? vsnprintf_l: http://www.unix.com/man-page/osx/3/printf_l/ uselocale: http://man7.org/linux/man-pages/man3/uselocale.3.html Marek On Wed, Dec 10, 2014 at 8:50 PM, Jose

[Mesa-dev] [PATCH 1/5] gallium/util: add a helper util_create_shader_from_text, cleanup some code

2014-12-09 Thread Marek Olšák
From: Marek Olšák marek.ol...@amd.com It's exposed, because I plan to use it elsewhere later. --- src/gallium/auxiliary/util/u_simple_shaders.c | 103 -- src/gallium/auxiliary/util/u_simple_shaders.h | 3 + 2 files changed, 49 insertions(+), 57 deletions(-) diff --git

Re: [Mesa-dev] [PATCH 1/5] gallium/util: add a helper util_create_shader_from_text, cleanup some code

2014-12-09 Thread Brian Paul
Series LGTM. Reviewed-by: Brian Paul bri...@vmware.com On 12/09/2014 04:28 AM, Marek Olšák wrote: From: Marek Olšák marek.ol...@amd.com It's exposed, because I plan to use it elsewhere later. --- src/gallium/auxiliary/util/u_simple_shaders.c | 103 --

Re: [Mesa-dev] [PATCH 1/5] gallium/util: add a helper util_create_shader_from_text, cleanup some code

2014-12-09 Thread Ilia Mirkin
On Tue, Dec 9, 2014 at 6:28 AM, Marek Olšák mar...@gmail.com wrote: diff --git a/src/gallium/auxiliary/util/u_simple_shaders.h b/src/gallium/auxiliary/util/u_simple_shaders.h index dd282e0..12f50f8 100644 --- a/src/gallium/auxiliary/util/u_simple_shaders.h +++