diff options
author | Diego Escalante Urrelo <descalante@igalia.com> | 2010-08-23 05:03:32 +0800 |
---|---|---|
committer | Diego Escalante Urrelo <descalante@igalia.com> | 2010-08-31 00:58:45 +0800 |
commit | 2544c3afd640d28782394e6a031f79ab6d90a641 (patch) | |
tree | aec22ce5585f865d9a37d7fb849afc340c5af3bb /embed | |
parent | 91e7be8d258530d52cf324becbaf6ed07f74d8f6 (diff) | |
download | gsoc2013-epiphany-2544c3afd640d28782394e6a031f79ab6d90a641.tar.gz gsoc2013-epiphany-2544c3afd640d28782394e6a031f79ab6d90a641.tar.zst gsoc2013-epiphany-2544c3afd640d28782394e6a031f79ab6d90a641.zip |
ephy-favicon-cache: remove failed download files
Bug #618627
Diffstat (limited to 'embed')
-rw-r--r-- | embed/ephy-favicon-cache.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/embed/ephy-favicon-cache.c b/embed/ephy-favicon-cache.c index db41eca51..23e528b78 100644 --- a/embed/ephy-favicon-cache.c +++ b/embed/ephy-favicon-cache.c @@ -508,9 +508,15 @@ favicon_download_status_changed_cb (WebKitDownload *download, g_hash_table_remove (cache->priv->downloads_hash, url); - /* TODO: remove a partially downloaded file */ /* FIXME: re-schedule to try again after n days? */ + file = g_file_new_for_uri (destination); + if (g_file_query_exists (file, NULL)) + { + LOG ("Deleting incomplete favicon download"); + g_file_delete (file, NULL, NULL); + } + g_object_unref (file); g_object_unref (download); cache->priv->dirty = TRUE; |