From: Peng Huang Date: Mon, 4 Jan 2010 01:33:52 +0000 (+0800) Subject: Remove some duplicate code. X-Git-Tag: 1.3.0~83 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=0168e6e8d18455557e3412aef86f1d74cd643e9d;p=platform%2Fupstream%2Fibus-libpinyin.git Remove some duplicate code. --- diff --git a/src/Database.cc b/src/Database.cc index a5f78f9..d214654 100644 --- a/src/Database.cc +++ b/src/Database.cc @@ -78,12 +78,12 @@ Database::init (void) m_sql.erase (0); -#if 0 +#if 1 /* Set synchronous=OFF, write user database will become much faster. - * It will cause user database corrupted, - * if the operatering system crashes or computer loses power. + * It will cause user database corrupted, if the operatering system + * crashes or computer loses power. * */ - m_sql << "PRAGMA synchronous=OFF;\n"; + m_sql << "PRAGMA synchronous=NORMAL;\n"; #endif /* Set the cache size for better performance */ @@ -95,9 +95,6 @@ Database::init (void) /* Set journal mode */ m_sql << "PRAGMA journal_mode=TRUNCATE;\n"; - /* Set the sync mode */ - m_sql << "PRAGMA synchronous=NORMAL;\n"; - /* Using EXCLUSIVE locking mode on main database * for better performance */ m_sql << "PRAGMA main.locking_mode=EXCLUSIVE;\n";