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

Unified Diff: chrome/browser/importer/firefox_importer_utils.cc

Issue 13145003: Rewrite std::string("") to std::string(), Linux edition. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Ugh Created 7 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
« no previous file with comments | « chrome/browser/history/thumbnail_database_unittest.cc ('k') | chrome/browser/internal_auth_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/importer/firefox_importer_utils.cc
diff --git a/chrome/browser/importer/firefox_importer_utils.cc b/chrome/browser/importer/firefox_importer_utils.cc
index 0535cf64bbefdc6f5ecade5291a20578cf06f7ec..8ffe8f2087fc7f9c6081fb6cf7c893cf80508d17 100644
--- a/chrome/browser/importer/firefox_importer_utils.cc
+++ b/chrome/browser/importer/firefox_importer_utils.cc
@@ -255,12 +255,12 @@ std::string ReadBrowserConfigProp(const base::FilePath& app_path,
const std::string& pref_key) {
std::string content;
if (!ReadPrefFile(app_path.AppendASCII("browserconfig.properties"), &content))
- return "";
+ return std::string();
// This file has the syntax: key=value.
size_t prop_index = content.find(pref_key + "=");
if (prop_index == std::string::npos)
- return "";
+ return std::string();
size_t start = prop_index + pref_key.length();
size_t stop = std::string::npos;
@@ -270,7 +270,7 @@ std::string ReadBrowserConfigProp(const base::FilePath& app_path,
if (start == std::string::npos ||
stop == std::string::npos || (start == stop)) {
LOG(WARNING) << "Firefox property " << pref_key << " could not be parsed.";
- return "";
+ return std::string();
}
return content.substr(start + 1, stop - start - 1);
@@ -280,7 +280,7 @@ std::string ReadPrefsJsValue(const base::FilePath& profile_path,
const std::string& pref_key) {
std::string content;
if (!ReadPrefFile(profile_path.AppendASCII("prefs.js"), &content))
- return "";
+ return std::string();
return GetPrefsJsValue(content, pref_key);
}
@@ -411,7 +411,7 @@ std::string GetPrefsJsValue(const std::string& content,
if (start == std::string::npos || stop == std::string::npos ||
stop < start) {
LOG(WARNING) << "Firefox property " << pref_key << " could not be parsed.";
- return "";
+ return std::string();
}
// String values have double quotes we don't need to return to the caller.
« no previous file with comments | « chrome/browser/history/thumbnail_database_unittest.cc ('k') | chrome/browser/internal_auth_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698