Merge pull request #328 from kordero/master

fixing sscanf issue with floats for certain locales
This commit is contained in:
Philip Rosedale 2013-05-15 23:36:04 -07:00
commit c8c4b8fda5

View file

@ -13,6 +13,8 @@
#error "This is an implementation file - not intended for direct inclusion."
#endif
#include <locale.h>
#include "Config.h"
#include "starfield/data/InputVertex.h"
@ -99,6 +101,7 @@ namespace starfield {
// parse
float azi, alt;
unsigned c;
setlocale(LC_NUMERIC, "C");
if (sscanf(line, " %f %f #%x", & azi, & alt, & c) == 3) {
if (spaceFor( getBrightness(c) )) {