summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormonsta <[email protected]>2018-04-28 16:04:10 +0300
committermonsta <[email protected]>2018-04-28 16:04:10 +0300
commit3b9119b3bb941de61654d45eb693a85f48d56289 (patch)
treee046a183ed045c956166b6dc5b6f05baea6c2b27
parent7099408402dc41f39e32f4afa3e874e968e879bc (diff)
downloadmate-panel-3b9119b3bb941de61654d45eb693a85f48d56289.tar.bz2
mate-panel-3b9119b3bb941de61654d45eb693a85f48d56289.tar.xz
clock: fix actual copy/paste error which caused use-after-free
also reverts 7099408402dc41f39e32f4afa3e874e968e879bc - not needed anymore
-rw-r--r--applets/clock/clock-location-tile.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/applets/clock/clock-location-tile.c b/applets/clock/clock-location-tile.c
index 11a14dcb..03717403 100644
--- a/applets/clock/clock-location-tile.c
+++ b/applets/clock/clock-location-tile.c
@@ -612,13 +612,13 @@ weather_info_setup_tooltip (WeatherInfo *info, ClockLocation *location, GtkToolt
else
line2 = g_strdup (temp);
g_free (temp);
+ g_free (apparent);
wind = weather_info_get_wind (info);
- if (strcmp (apparent, dgettext ("mate-applets-2.0", "Unknown")) != 0)
+ if (strcmp (wind, dgettext ("mate-applets-2.0", "Unknown")) != 0)
line3 = g_strdup_printf ("%s\n", wind);
else
line3 = g_strdup ("");
- g_free (apparent);
sys_timezone = getenv ("TZ");
setenv ("TZ", clock_location_get_timezone (location), 1);