summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorthomasvl@chromium.org <thomasvl@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-28 18:29:09 +0000
committerthomasvl@chromium.org <thomasvl@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-28 18:29:09 +0000
commit9d0e4b33204e3a7d18719778324fb08e545feaf9 (patch)
tree173c1242b08e580fe2ce51b44ca3835d54fe5c0a
parent2f82fb8b5067a9d93b85a5ecd16b14dace708ec5 (diff)
downloadchromium_src-9d0e4b33204e3a7d18719778324fb08e545feaf9.zip
chromium_src-9d0e4b33204e3a7d18719778324fb08e545feaf9.tar.gz
chromium_src-9d0e4b33204e3a7d18719778324fb08e545feaf9.tar.bz2
The CPP logic on the log dir seems to have been wrong since last year. Changed so debug writes next to the executable, and release writes to userdata dir. It was the reverse.
Drop two paths that aren't used any more. BUG=12834 TEST=run app, make sure we don't create a log file inside the MacOS folder. Review URL: http://codereview.chromium.org/115868 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17087 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/common/chrome_paths.cc24
-rw-r--r--chrome/common/chrome_paths.h2
2 files changed, 3 insertions, 23 deletions
diff --git a/chrome/common/chrome_paths.cc b/chrome/common/chrome_paths.cc
index 7987d34e..4645346 100644
--- a/chrome/common/chrome_paths.cc
+++ b/chrome/common/chrome_paths.cc
@@ -37,9 +37,11 @@ bool PathProvider(int key, FilePath* result) {
case chrome::DIR_APP:
return PathService::Get(base::DIR_MODULE, result);
case chrome::DIR_LOGS:
-#ifndef NDEBUG
+#ifdef NDEBUG
+ // Release builds write to the data dir
return PathService::Get(chrome::DIR_USER_DATA, result);
#else
+ // Debug builds write next to the binary (in the build tree)
return PathService::Get(base::DIR_EXE, result);
#endif
case chrome::FILE_RESOURCE_MODULE:
@@ -161,26 +163,6 @@ bool PathProvider(int key, FilePath* result) {
if (!file_util::PathExists(cur)) // we don't want to create this
return false;
break;
- case chrome::FILE_PYTHON_RUNTIME:
- if (!PathService::Get(base::DIR_SOURCE_ROOT, &cur))
- return false;
- cur = cur.Append(FILE_PATH_LITERAL("third_party"));
- cur = cur.Append(FILE_PATH_LITERAL("python_24"));
- cur = cur.Append(FILE_PATH_LITERAL("python.exe"));
- if (!file_util::PathExists(cur)) // we don't want to create this
- return false;
- break;
- case chrome::FILE_TEST_SERVER:
- if (!PathService::Get(base::DIR_SOURCE_ROOT, &cur))
- return false;
- cur = cur.Append(FILE_PATH_LITERAL("net"));
- cur = cur.Append(FILE_PATH_LITERAL("tools"));
- cur = cur.Append(FILE_PATH_LITERAL("test"));
- cur = cur.Append(FILE_PATH_LITERAL("testserver"));
- cur = cur.Append(FILE_PATH_LITERAL("testserver.py"));
- if (!file_util::PathExists(cur)) // we don't want to create this
- return false;
- break;
default:
return false;
}
diff --git a/chrome/common/chrome_paths.h b/chrome/common/chrome_paths.h
index 811fe57..c5191c3 100644
--- a/chrome/common/chrome_paths.h
+++ b/chrome/common/chrome_paths.h
@@ -36,8 +36,6 @@ enum {
// Valid only in development environment; TODO(darin): move these
DIR_TEST_DATA, // directory where unit test data resides
DIR_TEST_TOOLS, // directory where unit test tools reside
- FILE_TEST_SERVER, // simple HTTP server for testing the network stack
- FILE_PYTHON_RUNTIME, // Python runtime, used for running the test server
PATH_END
};