[epiphany/gnome-3-22] history-service: Initialize tables even in read-only mode



commit 6666530fa0afee89371413ffaa59a2a81eba2b8d
Author: Michael Catanzaro <mcatanzaro gnome org>
Date:   Fri Oct 28 06:04:49 2016 -0500

    history-service: Initialize tables even in read-only mode
    
    The history service just is not built to handle the case where no
    history tables exist. We either need to upgrade every error path in this
    directory to not call g_warning in read-only mode, or just create the
    tables. Creating tables is harmless; we just don't want to insert
    history into them.

 lib/history/ephy-history-service.c |    3 ---
 1 files changed, 0 insertions(+), 3 deletions(-)
---
diff --git a/lib/history/ephy-history-service.c b/lib/history/ephy-history-service.c
index 276f264..e90239f 100644
--- a/lib/history/ephy-history-service.c
+++ b/lib/history/ephy-history-service.c
@@ -383,9 +383,6 @@ ephy_history_service_open_database_connections (EphyHistoryService *self)
 
   ephy_history_service_enable_foreign_keys (self);
 
-  if (self->read_only)
-    return TRUE;
-
   ephy_sqlite_connection_begin_transaction (self->history_database, &error);
   if (error) {
     g_warning ("Could not begin long running transaction in history database: %s", error->message);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]