summaryrefslogtreecommitdiffstats
path: root/chrome/browser/importer/importer.cc
diff options
context:
space:
mode:
authorjhawkins@chromium.org <jhawkins@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-02-27 04:29:26 +0000
committerjhawkins@chromium.org <jhawkins@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-02-27 04:29:26 +0000
commitdf2013932664ec3718248ed7c6f41445bb939a10 (patch)
tree49c2eb838e9a7cff2e47ea3afef0c3c9d8dee406 /chrome/browser/importer/importer.cc
parent5a43a8d52d5c369beb16b52a8a32315a228f804b (diff)
downloadchromium_src-df2013932664ec3718248ed7c6f41445bb939a10.zip
chromium_src-df2013932664ec3718248ed7c6f41445bb939a10.tar.gz
chromium_src-df2013932664ec3718248ed7c6f41445bb939a10.tar.bz2
Re-land r10564 with a fix for unit tests. Fixed a typo in an ifdef.
Make firefox_importer_utils.cc compile on Posix. TBR=evan Review URL: http://codereview.chromium.org/29006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10584 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/importer/importer.cc')
-rw-r--r--chrome/browser/importer/importer.cc9
1 files changed, 8 insertions, 1 deletions
diff --git a/chrome/browser/importer/importer.cc b/chrome/browser/importer/importer.cc
index 6a2e59f..9c98362 100644
--- a/chrome/browser/importer/importer.cc
+++ b/chrome/browser/importer/importer.cc
@@ -647,9 +647,14 @@ void ImporterHost::DetectFirefoxProfiles() {
return;
}
- std::wstring ini_file = GetProfilesINI();
DictionaryValue root;
+#if defined(OS_WIN)
+ std::wstring ini_file = GetProfilesINI();
ParseProfileINI(ini_file, &root);
+#else
+ // TODO(port): Do we need to concern ourselves with profiles on posix?
+ NOTIMPLEMENTED();
+#endif
std::wstring source_path;
for (int i = 0; ; ++i) {
@@ -664,6 +669,7 @@ void ImporterHost::DetectFirefoxProfiles() {
root.GetString(current_profile + L".Path", &path)) {
ReplaceSubstringsAfterOffset(&path, 0, L"/", L"\\");
+#if defined(OS_WIN)
// IsRelative=1 means the folder path would be relative to the
// path of profiles.ini. IsRelative=0 refers to a custom profile
// location.
@@ -673,6 +679,7 @@ void ImporterHost::DetectFirefoxProfiles() {
} else {
profile_path = path;
}
+#endif
// We only import the default profile when multiple profiles exist,
// since the other profiles are used mostly by developers for testing.