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

Unified Diff: chrome/utility/importer/bookmark_html_reader.cc

Issue 1119453003: [Importer] Allow Chrome to import bookmark files without a charset specified. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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 side-by-side diff with in-line comments
Download patch
Index: chrome/utility/importer/bookmark_html_reader.cc
diff --git a/chrome/utility/importer/bookmark_html_reader.cc b/chrome/utility/importer/bookmark_html_reader.cc
index 2ba117152feaaeb611d46a51671262101fcff680..eed15fa1fbd53f0efa22bce30d940cd36a4e0c2d 100644
--- a/chrome/utility/importer/bookmark_html_reader.cc
+++ b/chrome/utility/importer/bookmark_html_reader.cc
@@ -106,7 +106,7 @@ void ImportBookmarksFile(
base::Time last_folder_add_date;
std::vector<base::string16> path;
size_t toolbar_folder_index = 0;
- std::string charset;
+ std::string charset = "UTF-8"; // If no charset is specified, assume utf-8.
for (size_t i = 0;
i < lines.size() &&
(cancellation_callback.is_null() || !cancellation_callback.Run());
« no previous file with comments | « chrome/test/data/bookmark_html_reader/ie_sans_charset.html ('k') | chrome/utility/importer/bookmark_html_reader_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698