diff options
author | Jon Bergli Heier <snakebite@jvnv.net> | 2009-12-23 03:08:08 +0100 |
---|---|---|
committer | Jon Bergli Heier <snakebite@jvnv.net> | 2009-12-23 03:08:08 +0100 |
commit | a539fdf38688cbed984d9db1f08deaaf34eaf9e0 (patch) | |
tree | 9cbae5f4d3a57ecf371409f8d06ae93a227b3614 | |
parent | 91e6eecfd4d75dcb2943203ca9739711a9a888ce (diff) |
Remember to free GError.
-rw-r--r-- | wallpapers.c | 1 | ||||
-rw-r--r-- | window_main.c | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/wallpapers.c b/wallpapers.c index 5e09742..6d7982a 100644 --- a/wallpapers.c +++ b/wallpapers.c @@ -94,6 +94,7 @@ void add_dir_recursive(const gchar *path, sqlite_uint64 parent, GtkStatusbar *st pixbuf = gdk_pixbuf_new_from_file(filepath, &error); if(!pixbuf) { g_warning("%s", error->message); + g_free(error); continue; } if(db_add_wallpaper(filepath, dirid, st.st_size, gdk_pixbuf_get_width(pixbuf), gdk_pixbuf_get_height(pixbuf))) { diff --git a/window_main.c b/window_main.c index 9ebacde..cfc24c6 100644 --- a/window_main.c +++ b/window_main.c @@ -189,6 +189,7 @@ void on_add_dir_action_activate(GtkAction *action, gpointer user_data) { add_thread = g_thread_create(add_dir_thread, strdup(directory), FALSE, &error); if(!add_thread) { g_warning("%s", error->message); + g_free(error); } } else printf("no directory selected\n"); |