[GRASS-SVN] r32077 -
grass/branches/develbranch_6/gui/wxpython/vdigit
svn_grass at osgeo.org
svn_grass at osgeo.org
Fri Jul 11 11:53:44 EDT 2008
Author: martinl
Date: 2008-07-11 11:53:44 -0400 (Fri, 11 Jul 2008)
New Revision: 32077
Modified:
grass/branches/develbranch_6/gui/wxpython/vdigit/digit.cpp
grass/branches/develbranch_6/gui/wxpython/vdigit/driver.cpp
Log:
wxGUI/vdigit: do not crash when LC_CNUMERIC != C, related to trac #225 (merged from trunk, r32076)
Modified: grass/branches/develbranch_6/gui/wxpython/vdigit/digit.cpp
===================================================================
--- grass/branches/develbranch_6/gui/wxpython/vdigit/digit.cpp 2008-07-11 15:48:51 UTC (rev 32076)
+++ grass/branches/develbranch_6/gui/wxpython/vdigit/digit.cpp 2008-07-11 15:53:44 UTC (rev 32077)
@@ -14,6 +14,8 @@
\date 2008
*/
+#include <clocale>
+
#include "driver.h"
#include "digit.h"
@@ -24,6 +26,8 @@
*/
Digit::Digit(DisplayDriver *ddriver)
{
+ setlocale(LC_NUMERIC, "C");
+
display = ddriver;
if (display->mapInfo) {
Modified: grass/branches/develbranch_6/gui/wxpython/vdigit/driver.cpp
===================================================================
--- grass/branches/develbranch_6/gui/wxpython/vdigit/driver.cpp 2008-07-11 15:48:51 UTC (rev 32076)
+++ grass/branches/develbranch_6/gui/wxpython/vdigit/driver.cpp 2008-07-11 15:53:44 UTC (rev 32077)
@@ -17,6 +17,7 @@
*/
#include <cmath>
+#include <clocale>
#include "driver.h"
@@ -31,6 +32,8 @@
*/
DisplayDriver::DisplayDriver(void *device)
{
+ setlocale(LC_NUMERIC, "C");
+
G_gisinit(""); /* GRASS functions */
mapInfo = NULL;
More information about the grass-commit
mailing list