aboutsummaryrefslogtreecommitdiffstats
path: root/embed
diff options
context:
space:
mode:
Diffstat (limited to 'embed')
-rw-r--r--embed/ephy-favicon-cache.c8
-rw-r--r--embed/ephy-history.c8
2 files changed, 16 insertions, 0 deletions
diff --git a/embed/ephy-favicon-cache.c b/embed/ephy-favicon-cache.c
index f38ddc3a6..25cc0e11b 100644
--- a/embed/ephy-favicon-cache.c
+++ b/embed/ephy-favicon-cache.c
@@ -196,7 +196,11 @@ icon_is_obsolete (EphyNode *node, GDate *now)
(node, EPHY_NODE_FAVICON_PROP_LAST_USED);
g_date_clear (&date, 1);
+#if GLIB_CHECK_VERSION (2,9,0)
+ g_date_set_time_t (&date, last_visit);
+#else
g_date_set_time (&date, last_visit);
+#endif
return (g_date_days_between (&date, now) >=
EPHY_FAVICON_CACHE_OBSOLETE_DAYS);
@@ -236,7 +240,11 @@ remove_obsolete_icons (EphyFaviconCache *cache,
GDate current_date;
g_date_clear (&current_date, 1);
+#if GLIB_CHECK_VERSION (2,9,0)
+ g_date_set_time_t (&current_date, time (NULL));
+#else
g_date_set_time (&current_date, time (NULL));
+#endif
children = ephy_node_get_children (priv->icons);
for (i = (int) children->len - 1; i >= 0; i--)
diff --git a/embed/ephy-history.c b/embed/ephy-history.c
index ad02c1655..7b542be76 100644
--- a/embed/ephy-history.c
+++ b/embed/ephy-history.c
@@ -247,7 +247,11 @@ page_is_obsolete (EphyNode *node, GDate *now)
(node, EPHY_NODE_PAGE_PROP_LAST_VISIT);
g_date_clear (&date, 1);
+#if GLIB_CHECK_VERSION (2,9,0)
+ g_date_set_time_t (&date, last_visit);
+#else
g_date_set_time (&date, last_visit);
+#endif
return (g_date_days_between (&date, now) >=
HISTORY_PAGE_OBSOLETE_DAYS);
@@ -263,7 +267,11 @@ remove_obsolete_pages (EphyHistory *eb)
now = time (NULL);
g_date_clear (&current_date, 1);
+#if GLIB_CHECK_VERSION (2,9,0)
+ g_date_set_time_t (&current_date, time (NULL));
+#else
g_date_set_time (&current_date, time (NULL));
+#endif
children = ephy_node_get_children (eb->priv->pages);
for (i = (int) children->len - 1; i >= 0; i--)