[Mesa-dev] [PATCH] glsl: add a missing call to _mesa_locale_init
Ilia Mirkin
imirkin at alum.mit.edu
Thu Jul 2 14:22:12 PDT 2015
Can this be done at dlopen/init time? For example what happens if you do
static int foo = _mesa_locale_init()
IIRC things like that are possible in C++, not sure about C.
On Thu, Jul 2, 2015 at 5:18 PM, Erik Faye-Lund <kusmabite at gmail.com> wrote:
> After c61bc6e ("util: port _mesa_strto[df] to C"), "make check"
> fails due to a missing _mesa_locale_init. Fixup this oversight.
>
> Signed-off-by: Erik Faye-Lund <kusmabite at gmail.com>
> Tested-by: Vinson Lee <vlee at freedesktop.org>
> ---
> src/glsl/test.cpp | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/src/glsl/test.cpp b/src/glsl/test.cpp
> index b1ff92e..9dc7c47 100644
> --- a/src/glsl/test.cpp
> +++ b/src/glsl/test.cpp
> @@ -37,6 +37,7 @@
> #include <stdio.h>
> #include <stdlib.h>
> #include <string.h>
> +#include "util/strtod.h"
>
> #include "test_optpass.h"
>
> @@ -67,6 +68,9 @@ static const char *extract_command_from_argv(int *argc, char **argv)
> int main(int argc, char **argv)
> {
> const char *command = extract_command_from_argv(&argc, argv);
> +
> + _mesa_locale_init();
> +
> if (strcmp(command, "optpass") == 0) {
> return test_optpass(argc, argv);
> } else {
> --
> 2.1.4
>
More information about the mesa-dev
mailing list