Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(250)

Issue 217613002: Misc. cleanup found while mucking with search engines code: (Closed)

Created:
6 years, 9 months ago by Peter Kasting
Modified:
6 years, 8 months ago
CC:
chromium-reviews, benquan, browser-components-watch_chromium.org, Dane Wallinga, dyu1, estade+watch_chromium.org, Ilya Sherman, rouslan+autofillwatch_chromium.org
Visibility:
Public.

Description

Misc. cleanup found while mucking with search engines code: * Don't handle DCHECK failure * Remove NOTREACHED()/LOG(ERROR) from cases that look like they could legitimately happen * All lines of args should begin at the same position * WebDataService::SetDefaultSearchProvider() doesn't actually need a full TemplateURL, just an ID * Use GetCachedStatement correctly, and in more places * Make KeywordTableTest a friend of KeywordTable to reduce FRIEND_TEST declarations and in preparation for making Add/Update/RemoveKeyword private * Data members should be private, not protected * Function declarations: all args on first line or one arg per line * Fix misspelling BUG=none TEST=none R=shess@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=260933

Patch Set 1 #

Total comments: 6
Unified diffs Side-by-side diffs Delta from patch set Stats (+176 lines, -236 lines) Patch
M chrome/browser/search_engines/template_url_service.cc View 8 chunks +7 lines, -19 lines 0 comments Download
M chrome/browser/webdata/keyword_table.h View 1 chunk +1 line, -3 lines 0 comments Download
M chrome/browser/webdata/keyword_table.cc View 3 chunks +13 lines, -12 lines 4 comments Download
M chrome/browser/webdata/keyword_table_unittest.cc View 7 chunks +105 lines, -136 lines 0 comments Download
M chrome/browser/webdata/web_data_service.h View 2 chunks +10 lines, -10 lines 0 comments Download
M chrome/browser/webdata/web_data_service.cc View 4 chunks +30 lines, -35 lines 0 comments Download
M components/webdata/common/web_data_service_backend.cc View 1 chunk +4 lines, -6 lines 0 comments Download
M sql/connection.h View 1 chunk +1 line, -1 line 0 comments Download
M sql/transaction.cc View 1 chunk +5 lines, -14 lines 2 comments Download

Messages

Total messages: 6 (0 generated)
Peter Kasting
6 years, 9 months ago (2014-03-28 21:37:11 UTC) #1
Scott Hess - ex-Googler
https://codereview.chromium.org/217613002/diff/1/chrome/browser/webdata/keyword_table.cc File chrome/browser/webdata/keyword_table.cc (right): https://codereview.chromium.org/217613002/diff/1/chrome/browser/webdata/keyword_table.cc#newcode249 chrome/browser/webdata/keyword_table.cc:249: sql::Statement s(db_->GetCachedStatement(SQL_FROM_HERE, query.c_str())); I hate constructed queries with a ...
6 years, 8 months ago (2014-03-31 18:09:07 UTC) #2
Peter Kasting
https://codereview.chromium.org/217613002/diff/1/chrome/browser/webdata/keyword_table.cc File chrome/browser/webdata/keyword_table.cc (right): https://codereview.chromium.org/217613002/diff/1/chrome/browser/webdata/keyword_table.cc#newcode249 chrome/browser/webdata/keyword_table.cc:249: sql::Statement s(db_->GetCachedStatement(SQL_FROM_HERE, query.c_str())); On 2014/03/31 18:09:08, shess wrote: > ...
6 years, 8 months ago (2014-03-31 19:53:56 UTC) #3
Scott Hess - ex-Googler
OK, while I don't fully agree with you on the desirability of the Transaction change, ...
6 years, 8 months ago (2014-03-31 23:52:08 UTC) #4
Peter Kasting
https://codereview.chromium.org/217613002/diff/1/chrome/browser/webdata/keyword_table.cc File chrome/browser/webdata/keyword_table.cc (right): https://codereview.chromium.org/217613002/diff/1/chrome/browser/webdata/keyword_table.cc#newcode249 chrome/browser/webdata/keyword_table.cc:249: sql::Statement s(db_->GetCachedStatement(SQL_FROM_HERE, query.c_str())); On 2014/03/31 23:52:08, shess wrote: > ...
6 years, 8 months ago (2014-04-01 00:18:55 UTC) #5
Peter Kasting
6 years, 8 months ago (2014-04-01 20:18:19 UTC) #6
Message was sent while issue was closed.
Committed patchset #1 manually as r260933 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698