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

Side by Side Diff: chrome/plugin/plugin_main.cc

Issue 4870001: Enable sandboxed flash on windows by default.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/common/sandbox_policy.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "build/build_config.h" 5 #include "build/build_config.h"
6 6
7 #if defined(OS_WIN) 7 #if defined(OS_WIN)
8 #include <objbase.h> 8 #include <objbase.h>
9 #include <windows.h> 9 #include <windows.h>
10 #endif 10 #endif
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 102
103 #elif defined(OS_WIN) 103 #elif defined(OS_WIN)
104 sandbox::TargetServices* target_services = 104 sandbox::TargetServices* target_services =
105 parameters.sandbox_info_.TargetServices(); 105 parameters.sandbox_info_.TargetServices();
106 106
107 CoInitialize(NULL); 107 CoInitialize(NULL);
108 DVLOG(1) << "Started plugin with " 108 DVLOG(1) << "Started plugin with "
109 << parsed_command_line.command_line_string(); 109 << parsed_command_line.command_line_string();
110 110
111 HMODULE sandbox_test_module = NULL; 111 HMODULE sandbox_test_module = NULL;
112 bool no_sandbox = parsed_command_line.HasSwitch(switches::kNoSandbox) || 112 bool no_sandbox = parsed_command_line.HasSwitch(switches::kNoSandbox);
113 !parsed_command_line.HasSwitch(switches::kSafePlugins); 113
114 if (target_services && !no_sandbox) { 114 if (target_services && !no_sandbox) {
115 // The command line might specify a test plugin to load. 115 // The command line might specify a test plugin to load.
116 if (parsed_command_line.HasSwitch(switches::kTestSandbox)) { 116 if (parsed_command_line.HasSwitch(switches::kTestSandbox)) {
117 std::wstring test_plugin_name = 117 std::wstring test_plugin_name =
118 parsed_command_line.GetSwitchValueNative(switches::kTestSandbox); 118 parsed_command_line.GetSwitchValueNative(switches::kTestSandbox);
119 sandbox_test_module = LoadLibrary(test_plugin_name.c_str()); 119 sandbox_test_module = LoadLibrary(test_plugin_name.c_str());
120 DCHECK(sandbox_test_module); 120 DCHECK(sandbox_test_module);
121 } 121 }
122 } 122 }
123 #endif 123 #endif
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
164 164
165 MessageLoop::current()->Run(); 165 MessageLoop::current()->Run();
166 } 166 }
167 167
168 #if defined(OS_WIN) 168 #if defined(OS_WIN)
169 CoUninitialize(); 169 CoUninitialize();
170 #endif 170 #endif
171 171
172 return 0; 172 return 0;
173 } 173 }
OLDNEW
« no previous file with comments | « chrome/common/sandbox_policy.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698