diff options
author | Charles Kerr <charles.kerr@canonical.com> | 2012-04-23 13:46:19 -0500 |
---|---|---|
committer | Charles Kerr <charles.kerr@canonical.com> | 2012-04-23 13:46:19 -0500 |
commit | bd456c3baa0200b7f8876fc1646ae09dca39c1c2 (patch) | |
tree | 4d364570df44e8e2ba4b56c7c653f0818a9d60b1 /src | |
parent | d3b9fd16b24968091dccd52eb824c213a8b819d3 (diff) | |
parent | 31125e1a32660e4b07d30e37993ac7d09fec9ff6 (diff) | |
download | ayatana-indicator-datetime-bd456c3baa0200b7f8876fc1646ae09dca39c1c2.tar.gz ayatana-indicator-datetime-bd456c3baa0200b7f8876fc1646ae09dca39c1c2.tar.bz2 ayatana-indicator-datetime-bd456c3baa0200b7f8876fc1646ae09dca39c1c2.zip |
merge lp:~ted/indicator-datetime/lp773987 to switch the parsing of the lat and long to be non-locale based as it's returned from the webservice in C, we want to parse it using the decimal instead of a comma.
Diffstat (limited to 'src')
-rw-r--r-- | src/datetime-prefs-locations.c | 4 | ||||
-rw-r--r-- | src/datetime-prefs.c | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/src/datetime-prefs-locations.c b/src/datetime-prefs-locations.c index c0452d0..9f5b42c 100644 --- a/src/datetime-prefs-locations.c +++ b/src/datetime-prefs-locations.c @@ -201,8 +201,8 @@ timezone_selected (GtkEntryCompletion * widget, GtkTreeModel * model, CC_TIMEZONE_COMPLETION_LONGITUDE, &strlon, -1); - if (strlat && *strlat) lat = atof(strlat); - if (strlon && *strlon) lon = atof(strlon); + if (strlat && *strlat) lat = g_ascii_strtod(strlat, NULL); + if (strlon && *strlon) lon = g_ascii_strtod(strlon, NULL); CcTimezoneMap * tzmap = CC_TIMEZONE_MAP (g_object_get_data (G_OBJECT (widget), "tzmap")); g_free (zone); diff --git a/src/datetime-prefs.c b/src/datetime-prefs.c index 615d601..611d9ef 100644 --- a/src/datetime-prefs.c +++ b/src/datetime-prefs.c @@ -613,11 +613,11 @@ timezone_selected (GtkEntryCompletion * widget, GtkTreeModel * model, -1); if (strlon != NULL && strlon[0] != 0) { - lon = strtod(strlon, NULL); + lon = g_ascii_strtod(strlon, NULL); } if (strlat != NULL && strlat[0] != 0) { - lat = strtod(strlat, NULL); + lat = g_ascii_strtod(strlat, NULL); } zone = cc_timezone_map_get_timezone_at_coords (self->priv->tzmap, lon, lat); |