diff options
author | sky@google.com <sky@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-10-08 15:22:34 +0000 |
---|---|---|
committer | sky@google.com <sky@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-10-08 15:22:34 +0000 |
commit | fda28420d4964c01a7396be1c88695557c1d51b3 (patch) | |
tree | 5d1f89fde4db34f463e640dfefc5fa6aef65d6cf /chrome/browser/template_url_model.h | |
parent | 544545cd1e7c5697c7610a33dd2c94b2d7d1cfb0 (diff) | |
download | chromium_src-fda28420d4964c01a7396be1c88695557c1d51b3.zip chromium_src-fda28420d4964c01a7396be1c88695557c1d51b3.tar.gz chromium_src-fda28420d4964c01a7396be1c88695557c1d51b3.tar.bz2 |
Fixes crasher in TemplateURLModel that occurred when the db had
multiple keywords with the same prepopulate id. We had this for
Hungary.
BUG=3192
TEST=make sure you don't see any problems with keywords.
Review URL: http://codereview.chromium.org/6284
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@3008 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/template_url_model.h')
-rw-r--r-- | chrome/browser/template_url_model.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/chrome/browser/template_url_model.h b/chrome/browser/template_url_model.h index d540f89..8fd65a7 100644 --- a/chrome/browser/template_url_model.h +++ b/chrome/browser/template_url_model.h @@ -180,6 +180,12 @@ class TemplateURLModel : public WebDataServiceConsumer, virtual void OnWebDataServiceRequestDone(WebDataService::Handle h, const WDTypedResult* result); + // Removes (and deletes) TemplateURLs from |urls| that have duplicate + // prepopulate ids. Duplicate prepopulate ids are not allowed, but due to a + // bug it was possible get dups. This step is only called when the version + // number changes. + void RemoveDuplicatePrepopulateIDs(std::vector<const TemplateURL*>* urls); + // NotificationObserver method. TemplateURLModel listens for three // notification types: // . NOTIFY_HISTORY_URL_VISITED: adds keyword search terms if the visit |