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

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

Issue 10171014: Changed to Reset(bool clear_bound_vars) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix mac build error. Created 8 years, 8 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
« no previous file with comments | « chrome/browser/net/sqlite_server_bound_cert_store.cc ('k') | sql/connection_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/autofill_table.h" 5 #include "chrome/browser/webdata/autofill_table.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <limits> 8 #include <limits>
9 #include <map> 9 #include <map>
10 #include <set> 10 #include <set>
(...skipping 484 matching lines...) Expand 10 before | Expand all | Expand 10 after
495 cull_date_entry.BindString16(0, entries[i].key().name()); 495 cull_date_entry.BindString16(0, entries[i].key().name());
496 cull_date_entry.BindString16(1, entries[i].key().value()); 496 cull_date_entry.BindString16(1, entries[i].key().value());
497 cull_date_entry.BindInt64(2, 497 cull_date_entry.BindInt64(2,
498 entries[i].timestamps().empty() ? 0 : 498 entries[i].timestamps().empty() ? 0 :
499 entries[i].timestamps().front().ToTimeT()); 499 entries[i].timestamps().front().ToTimeT());
500 cull_date_entry.BindInt64(3, 500 cull_date_entry.BindInt64(3,
501 entries[i].timestamps().empty() ? 0 : 501 entries[i].timestamps().empty() ? 0 :
502 entries[i].timestamps().back().ToTimeT()); 502 entries[i].timestamps().back().ToTimeT());
503 if (!cull_date_entry.Run()) 503 if (!cull_date_entry.Run())
504 return false; 504 return false;
505 cull_date_entry.Reset(); 505 cull_date_entry.Reset(true);
506 } 506 }
507 507
508 changes->clear(); 508 changes->clear();
509 changes->reserve(entries_to_delete.size()); 509 changes->reserve(entries_to_delete.size());
510 510
511 for (AutofillElementList::iterator it = entries_to_delete.begin(); 511 for (AutofillElementList::iterator it = entries_to_delete.begin();
512 it != entries_to_delete.end(); ++it) { 512 it != entries_to_delete.end(); ++it) {
513 changes->push_back(AutofillChange( 513 changes->push_back(AutofillChange(
514 AutofillChange::REMOVE, AutofillKey(it->b, it->c))); 514 AutofillChange::REMOVE, AutofillKey(it->b, it->c)));
515 } 515 }
(...skipping 1462 matching lines...) Expand 10 before | Expand all | Expand 10 after
1978 "WHERE guid=?")); 1978 "WHERE guid=?"));
1979 s_date.BindInt64(0, date_item->second); 1979 s_date.BindInt64(0, date_item->second);
1980 s_date.BindString(1, iter->guid()); 1980 s_date.BindString(1, iter->guid());
1981 1981
1982 if (!s_date.Run()) 1982 if (!s_date.Run())
1983 return false; 1983 return false;
1984 } 1984 }
1985 1985
1986 return true; 1986 return true;
1987 } 1987 }
OLDNEW
« no previous file with comments | « chrome/browser/net/sqlite_server_bound_cert_store.cc ('k') | sql/connection_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698