diff options
author | Alex Deucher <alexdeucher@gmail.com> | 2009-10-19 12:10:59 -0400 |
---|---|---|
committer | Alex Deucher <alexdeucher@gmail.com> | 2009-10-19 12:10:59 -0400 |
commit | 620270c76e7241fe4c391e31e3706468d708fe69 (patch) | |
tree | da8664d287043ab9db78500609f460d2c6d0b59d /src/mesa/main | |
parent | 35b98e2884bd7c76c43fa08d5bb0a8f1396d3298 (diff) | |
parent | 16e21191e26084848c7e6e3ffd9e15ef670855c5 (diff) |
Merge branch 'mesa_7_6_branch' of git+ssh://agd5f@git.freedesktop.org/git/mesa/mesa
regenerated lex.yy.c
Diffstat (limited to 'src/mesa/main')
-rw-r--r-- | src/mesa/main/imports.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/mesa/main/imports.c b/src/mesa/main/imports.c index 6ffaddcde9..87cb5ce0fb 100644 --- a/src/mesa/main/imports.c +++ b/src/mesa/main/imports.c @@ -48,6 +48,10 @@ #include "context.h" #include "version.h" +#ifdef _GNU_SOURCE +#include <locale.h> +#endif + #define MAXSTRING 4000 /* for vsnprintf() */ @@ -908,7 +912,15 @@ _mesa_atoi(const char *s) double _mesa_strtod( const char *s, char **end ) { +#ifdef _GNU_SOURCE + static locale_t loc = NULL; + if (!loc) { + loc = newlocale(LC_CTYPE_MASK, "C", NULL); + } + return strtod_l(s, end, loc); +#else return strtod(s, end); +#endif } /** Compute simple checksum/hash for a string */ |