diff options
author | rbuj <[email protected]> | 2019-03-14 08:52:34 +0100 |
---|---|---|
committer | ZenWalker <[email protected]> | 2019-04-14 14:38:44 +0200 |
commit | 538e7566185ccd4f6accd55fcb55644c0223d82f (patch) | |
tree | 67974a2fc1797bbb4e7403f6fa0aa6b40b71821b /battstat/battstat_applet.c | |
parent | b2bd59f9559c161876515ee6696d5c8c94f0f49a (diff) | |
download | mate-applets-538e7566185ccd4f6accd55fcb55644c0223d82f.tar.bz2 mate-applets-538e7566185ccd4f6accd55fcb55644c0223d82f.tar.xz |
Fix use-after-free clang warning
battstat_applet.c:755:3: warning: Use of memory after it is freed
static_global_teardown (battstat);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
stickynotes.c:674:24: warning: Use of memory after it is freed
stickynotes->notes = g_list_remove(stickynotes->notes, note);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Diffstat (limited to 'battstat/battstat_applet.c')
-rw-r--r-- | battstat/battstat_applet.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/battstat/battstat_applet.c b/battstat/battstat_applet.c index bb52c7fd..dd66b4f5 100644 --- a/battstat/battstat_applet.c +++ b/battstat/battstat_applet.c @@ -750,9 +750,9 @@ destroy_applet( GtkWidget *widget, ProgressData *battstat ) g_object_unref( G_OBJECT(battstat->status) ); g_object_unref( G_OBJECT(battstat->percent) ); - g_free( battstat ); - static_global_teardown (battstat); + + g_free (battstat); } /* Common function invoked by the 'Help' context menu item and the 'Help' |