[epiphany/gnome-3-18] Revert "downloads: Value returned by ephy_download_get_content_type() should not be freed"
- From: Michael Catanzaro <mcatanzaro src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [epiphany/gnome-3-18] Revert "downloads: Value returned by ephy_download_get_content_type() should not be freed"
- Date: Fri, 11 Dec 2015 10:20:15 +0000 (UTC)
commit 00f54fc48c8d04ca62f2d672d2cbbcdc12e4393e
Author: Michael Catanzaro <mcatanzaro igalia com>
Date: Fri Dec 11 11:18:25 2015 +0100
Revert "downloads: Value returned by ephy_download_get_content_type() should not be freed"
This reverts commit 3d1a0d0d1997595cc2a885ac040c729097ee5595.
In Epiphany 3.18, this still needs to be freed. The bug was introduced in
f379cfbae025b9c1fe667223cbcbffa893e30c0f after branching for gnome-3-18.
embed/ephy-download.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/embed/ephy-download.c b/embed/ephy-download.c
index 8919afe..b3364e9 100644
--- a/embed/ephy-download.c
+++ b/embed/ephy-download.c
@@ -195,7 +195,7 @@ ephy_download_get_content_type (EphyDownload *download)
static EphyDownloadActionType
decide_action_from_mime (EphyDownload *ephy_download)
{
- const char *content_type;
+ char *content_type;
GAppInfo *helper_app = NULL;
EphyDownloadActionType action;
@@ -204,6 +204,8 @@ decide_action_from_mime (EphyDownload *ephy_download)
helper_app = g_app_info_get_default_for_type (content_type, FALSE);
if (helper_app)
action = EPHY_DOWNLOAD_ACTION_OPEN;
+
+ g_free (content_type);
}
/* Downloads that have no content_type, or no helper_app, are
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]