aboutsummaryrefslogtreecommitdiffstats
path: root/modules
diff options
context:
space:
mode:
Diffstat (limited to 'modules')
-rw-r--r--modules/cal-config-weather/e-source-weather.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/modules/cal-config-weather/e-source-weather.c b/modules/cal-config-weather/e-source-weather.c
index 4ba306408a..fb0ede7aa9 100644
--- a/modules/cal-config-weather/e-source-weather.c
+++ b/modules/cal-config-weather/e-source-weather.c
@@ -212,21 +212,17 @@ void
e_source_weather_set_location (ESourceWeather *extension,
const gchar *location)
{
- gchar *new_location;
-
g_return_if_fail (E_IS_SOURCE_WEATHER (extension));
g_mutex_lock (&extension->priv->property_lock);
- new_location = e_util_strdup_strip (location);
- if (g_strcmp0 (extension->priv->location, new_location) == 0) {
+ if (g_strcmp0 (extension->priv->location, location) == 0) {
g_mutex_unlock (&extension->priv->property_lock);
- g_free (new_location);
return;
}
g_free (extension->priv->location);
- extension->priv->location = new_location;
+ extension->priv->location = e_util_strdup_strip (location);
g_mutex_unlock (&extension->priv->property_lock);