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

Side by Side Diff: chrome/browser/webdata/web_data_service.cc

Issue 12258039: enable -Wstring-conversion when compiling with clang (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: enable warning, fix some locations, disable for some subprojects Created 7 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/webdata/web_data_service.h" 5 #include "chrome/browser/webdata/web_data_service.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/message_loop.h" 8 #include "base/message_loop.h"
9 #include "base/stl_util.h" 9 #include "base/stl_util.h"
10 #include "base/threading/thread.h" 10 #include "base/threading/thread.h"
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after
324 void WebDataService::RemoveAutofillProfilesAndCreditCardsModifiedBetween( 324 void WebDataService::RemoveAutofillProfilesAndCreditCardsModifiedBetween(
325 const Time& delete_begin, 325 const Time& delete_begin,
326 const Time& delete_end) { 326 const Time& delete_end) {
327 ScheduleDBTask(FROM_HERE, Bind( 327 ScheduleDBTask(FROM_HERE, Bind(
328 &WebDataService::RemoveAutofillProfilesAndCreditCardsModifiedBetweenImpl, 328 &WebDataService::RemoveAutofillProfilesAndCreditCardsModifiedBetweenImpl,
329 this, delete_begin, delete_end)); 329 this, delete_begin, delete_end));
330 } 330 }
331 331
332 WebDataService::~WebDataService() { 332 WebDataService::~WebDataService() {
333 if (is_running_ && db_) { 333 if (is_running_ && db_) {
334 DLOG_ASSERT("WebDataService dtor called without Shutdown"); 334 DLOG_ASSERT(false) << "WebDataService dtor called without Shutdown";
335 NOTREACHED(); 335 NOTREACHED();
Nico 2013/02/21 20:36:00 NOTREACHED() << "WebDataService dtor called withou
scottmg 2013/02/21 20:47:57 Done.
336 } 336 }
337 } 337 }
338 338
339 bool WebDataService::InitWithPath(const base::FilePath& path) { 339 bool WebDataService::InitWithPath(const base::FilePath& path) {
340 path_ = path; 340 path_ = path;
341 is_running_ = true; 341 is_running_ = true;
342 342
343 ScheduleTask(FROM_HERE, 343 ScheduleTask(FROM_HERE,
344 Bind(&WebDataService::InitializeDatabaseIfNecessary, this)); 344 Bind(&WebDataService::InitializeDatabaseIfNecessary, this));
345 ScheduleTask(FROM_HERE, 345 ScheduleTask(FROM_HERE,
(...skipping 600 matching lines...) Expand 10 before | Expand all | Expand 10 after
946 946
947 void WebDataService::DestroyAutofillCreditCardResult( 947 void WebDataService::DestroyAutofillCreditCardResult(
948 const WDTypedResult* result) { 948 const WDTypedResult* result) {
949 DCHECK(result->GetType() == AUTOFILL_CREDITCARDS_RESULT); 949 DCHECK(result->GetType() == AUTOFILL_CREDITCARDS_RESULT);
950 const WDResult<std::vector<CreditCard*> >* r = 950 const WDResult<std::vector<CreditCard*> >* r =
951 static_cast<const WDResult<std::vector<CreditCard*> >*>(result); 951 static_cast<const WDResult<std::vector<CreditCard*> >*>(result);
952 952
953 std::vector<CreditCard*> credit_cards = r->GetValue(); 953 std::vector<CreditCard*> credit_cards = r->GetValue();
954 STLDeleteElements(&credit_cards); 954 STLDeleteElements(&credit_cards);
955 } 955 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698