bug-glpk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-glpk] LANG variable v4.43


From: Andrew Makhorin
Subject: Re: [Bug-glpk] LANG variable v4.43
Date: Thu, 15 Apr 2010 14:24:37 +0400

> I think I found a bug (or an unexpected feature?):

> When parsing a gnumath file I got an error:
> variableName requires numeric data
> Context:  0 1 0 0 0 0 0 0 0 0 ; param variableName := 1 0.2

> The problem was my language setting: I used LANG=de_DE which implies
> that floats are written with a comma, not a point: "0,2" would be
> correct with this language setting.

> Is it a bug? I'm not sure. From the examples given in the gnumath
> manual I would expect float to be written with a point.

> Some context information:
> OS: Linux
> Distribution: Debian Squeeze and Gentoo Stable
> GLPK version: 4.43

Thank you for your report.

All glpk routines assume the standard C locale. Thus, if your program
sets (directly or through environment variables) a locale other than C,
you need to temporarily restore the C locale with the standard function
setlocale when you call glpk api routines. If you are using glpsol,
you need to temporarily change the value of LANG environment variable
to specify the standard C locale.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]