aboutsummaryrefslogtreecommitdiffstats
path: root/lib/history
diff options
context:
space:
mode:
authorClaudio Saavedra <csaavedra@igalia.com>2012-01-11 01:11:08 +0800
committerXan Lopez <xan@igalia.com>2012-03-07 04:49:44 +0800
commit29227ae52d3d3921ddbbf23e4ad0bc9bf294e793 (patch)
treea23d0302164a17c60e038e609cf2e40534b9ef68 /lib/history
parent376dfb96be3926380ce58497be2241519fa8c556 (diff)
downloadgsoc2013-epiphany-29227ae52d3d3921ddbbf23e4ad0bc9bf294e793.tar
gsoc2013-epiphany-29227ae52d3d3921ddbbf23e4ad0bc9bf294e793.tar.gz
gsoc2013-epiphany-29227ae52d3d3921ddbbf23e4ad0bc9bf294e793.tar.bz2
gsoc2013-epiphany-29227ae52d3d3921ddbbf23e4ad0bc9bf294e793.tar.lz
gsoc2013-epiphany-29227ae52d3d3921ddbbf23e4ad0bc9bf294e793.tar.xz
gsoc2013-epiphany-29227ae52d3d3921ddbbf23e4ad0bc9bf294e793.tar.zst
gsoc2013-epiphany-29227ae52d3d3921ddbbf23e4ad0bc9bf294e793.zip
history-service: Ignore queries time range if not set
Diffstat (limited to 'lib/history')
-rw-r--r--lib/history/ephy-history-service-urls-table.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/history/ephy-history-service-urls-table.c b/lib/history/ephy-history-service-urls-table.c
index 3c7834bb8..4892fd4a5 100644
--- a/lib/history/ephy-history-service-urls-table.c
+++ b/lib/history/ephy-history-service-urls-table.c
@@ -248,9 +248,9 @@ ephy_history_service_find_url_rows (EphyHistoryService *self, EphyHistoryQuery *
statement_str = g_string_new (base_statement);
- if (query->from >= 0)
+ if (query->from > 0)
statement_str = g_string_append (statement_str, "visits.visit_time >= ? AND ");
- if (query->to >= 0)
+ if (query->to > 0)
statement_str = g_string_append (statement_str, "visits.visit_time <= ? AND ");
for (substring = query->substring_list; substring != NULL; substring = substring->next)
@@ -269,7 +269,7 @@ ephy_history_service_find_url_rows (EphyHistoryService *self, EphyHistoryQuery *
return NULL;
}
- if (query->from >= 0) {
+ if (query->from > 0) {
if (ephy_sqlite_statement_bind_int (statement, i++, (int)query->from, &error) == FALSE) {
g_error ("Could not build urls table query statement: %s", error->message);
g_error_free (error);
@@ -277,7 +277,7 @@ ephy_history_service_find_url_rows (EphyHistoryService *self, EphyHistoryQuery *
return NULL;
}
}
- if (query->to >= 0) {
+ if (query->to > 0) {
if (ephy_sqlite_statement_bind_int (statement, i++, (int)query->to, &error) == FALSE) {
g_error ("Could not build urls table query statement: %s", error->message);
g_error_free (error);