OLD | NEW |
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/password_manager/login_database.h" | 5 #include "chrome/browser/password_manager/login_database.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <limits> | 8 #include <limits> |
9 | 9 |
10 #include "base/file_util.h" | 10 #include "base/file_util.h" |
11 #include "base/files/file_path.h" | 11 #include "base/files/file_path.h" |
12 #include "base/logging.h" | 12 #include "base/logging.h" |
13 #include "base/metrics/histogram.h" | 13 #include "base/metrics/histogram.h" |
14 #include "base/pickle.h" | 14 #include "base/pickle.h" |
15 #include "base/strings/string_number_conversions.h" | 15 #include "base/strings/string_number_conversions.h" |
| 16 #include "base/strings/utf_string_conversions.h" |
16 #include "base/time.h" | 17 #include "base/time.h" |
17 #include "base/utf_string_conversions.h" | |
18 #include "sql/statement.h" | 18 #include "sql/statement.h" |
19 #include "sql/transaction.h" | 19 #include "sql/transaction.h" |
20 | 20 |
21 using content::PasswordForm; | 21 using content::PasswordForm; |
22 | 22 |
23 static const int kCurrentVersionNumber = 3; | 23 static const int kCurrentVersionNumber = 3; |
24 static const int kCompatibleVersionNumber = 1; | 24 static const int kCompatibleVersionNumber = 1; |
25 | 25 |
26 namespace { | 26 namespace { |
27 | 27 |
(...skipping 425 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
453 std::vector<string16> LoginDatabase::DeserializeVector(const Pickle& p) const { | 453 std::vector<string16> LoginDatabase::DeserializeVector(const Pickle& p) const { |
454 std::vector<string16> ret; | 454 std::vector<string16> ret; |
455 string16 str; | 455 string16 str; |
456 | 456 |
457 PickleIterator iterator(p); | 457 PickleIterator iterator(p); |
458 while (iterator.ReadString16(&str)) { | 458 while (iterator.ReadString16(&str)) { |
459 ret.push_back(str); | 459 ret.push_back(str); |
460 } | 460 } |
461 return ret; | 461 return ret; |
462 } | 462 } |
OLD | NEW |