]> www.fi.muni.cz Git - evince.git/blobdiff - pdf/xpdf/Function.cc
new widget: table with labels displaying properties of PDFs
[evince.git] / pdf / xpdf / Function.cc
index 64ea60c1902e6bbbcc8b7e3e3b0ef21ceb993fa6..6d70858a17fd747ceda1ccfd5cc5c05bba72871f 100644 (file)
@@ -11,6 +11,7 @@
 #endif
 
 #include <aconf.h>
+#include <locale.h>
 #include <stdlib.h>
 #include <string.h>
 #include <ctype.h>
@@ -1071,7 +1072,11 @@ GBool PostScriptFunction::parseCode(Stream *str, int *codePtr) {
       resizeCode(*codePtr);
       if (isReal) {
        code[*codePtr].type = psReal;
-       code[*codePtr].real = atof(tok->getCString());
+        {
+          char *theLocale = setlocale(LC_NUMERIC, "C");
+          code[*codePtr].real = atof(tok->getCString());
+          setlocale(LC_NUMERIC, theLocale);
+        }
       } else {
        code[*codePtr].type = psInt;
        code[*codePtr].intg = atoi(tok->getCString());