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

Unified Diff: base/command_line.cc

Issue 115773: Prototype implementation of zygotes (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 6 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 | « base/command_line.h ('k') | base/file_descriptor_shuffle.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/command_line.cc
===================================================================
--- base/command_line.cc (revision 17632)
+++ base/command_line.cc (working copy)
@@ -178,6 +178,17 @@
#endif
}
+// static
+void CommandLine::Init(const std::vector<std::string>& argv) {
+ DCHECK(current_process_commandline_ == NULL);
+#if defined(OS_WIN)
+ current_process_commandline_ = new CommandLine;
+ current_process_commandline_->ParseFromString(::GetCommandLineW());
+#elif defined(OS_POSIX)
+ current_process_commandline_ = new CommandLine(argv);
+#endif
+}
+
void CommandLine::Terminate() {
DCHECK(current_process_commandline_ != NULL);
delete current_process_commandline_;
« no previous file with comments | « base/command_line.h ('k') | base/file_descriptor_shuffle.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698