Bug#528564: [jmdlx] DWELL RATIO and HEIGHT RATIO change without reason

Torbjörn Andersson eriknospam at telia.com
Tue Aug 17 19:36:19 UTC 2010


 > Every time I load a pattern DWELL
 > RATIO and  HEIGHT RATIO change to 3 and 10.

I just installed this package, and I'm having the same problem. I think 
I see why.

The pattern parameters (DR, HR, etc.) are stored as floating-point 
numbers in the patterns file. These are then parsed using sscanf(). 
However, sscanf() is locale-dependent so this only works if the decimal 
point is a point and not something else. I live in Sweden, so in my 
locale the decimal point is a comma. The parameters are parsed as 
zeroes, which is adjusted to the lowest values allowed. (Though I 
thought that was 4 and 10, not 3 and 10. Hmm...)

I'm not sure what the proper fix is. Perhaps to set the LC_NUMERIC 
locale to "C" or something like that during the parsing and reset it 
afterwards, perhaps?

In the meantime, you could start it from a command prompt with 
"LC_NUMERIC=. jmdlx", and it should work. I think. There still appear to 
be a fair number of glitches in the user interface.

Sincerely,

Torbjörn Andersson





More information about the Pkg-games-devel mailing list