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

Side by Side Diff: chrome/renderer/chrome_content_renderer_client.cc

Issue 181343003: Revert of Link chrome_elf.dll instead of statically linking the blacklist code (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 6 years, 10 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 unified diff | Download patch
« no previous file with comments | « chrome/chrome_browser.gypi ('k') | chrome_elf/chrome_elf.def » ('j') | 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "chrome/renderer/chrome_content_renderer_client.h" 5 #include "chrome/renderer/chrome_content_renderer_client.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/debug/crash_logging.h" 8 #include "base/debug/crash_logging.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/metrics/histogram.h" 10 #include "base/metrics/histogram.h"
(...skipping 347 matching lines...) Expand 10 before | Expand all | Expand 10 after
358 WebSecurityPolicy::registerURLSchemeAsBypassingContentSecurityPolicy( 358 WebSecurityPolicy::registerURLSchemeAsBypassingContentSecurityPolicy(
359 extension_resource_scheme); 359 extension_resource_scheme);
360 360
361 extensions::ExtensionsClient::Set( 361 extensions::ExtensionsClient::Set(
362 extensions::ChromeExtensionsClient::GetInstance()); 362 extensions::ChromeExtensionsClient::GetInstance());
363 363
364 #if defined(OS_WIN) 364 #if defined(OS_WIN)
365 // Report if the renderer process has been patched by chrome_elf. 365 // Report if the renderer process has been patched by chrome_elf.
366 // TODO(csharp): Remove once the renderer is no longer getting 366 // TODO(csharp): Remove once the renderer is no longer getting
367 // patched this way. 367 // patched this way.
368 if (blacklist::IsBlacklistInitialized()) 368 typedef bool(*IsBlacklistInitializedFunc)();
369 IsBlacklistInitializedFunc is_blacklist_initialized =
370 reinterpret_cast<IsBlacklistInitializedFunc>(
371 GetProcAddress(GetModuleHandle(L"chrome_elf.dll"),
372 "IsBlacklistInitialized"));
373 if (is_blacklist_initialized && is_blacklist_initialized())
369 UMA_HISTOGRAM_BOOLEAN("Blacklist.PatchedInRenderer", true); 374 UMA_HISTOGRAM_BOOLEAN("Blacklist.PatchedInRenderer", true);
370 #endif 375 #endif
371 } 376 }
372 377
373 void ChromeContentRendererClient::RenderFrameCreated( 378 void ChromeContentRendererClient::RenderFrameCreated(
374 content::RenderFrame* render_frame) { 379 content::RenderFrame* render_frame) {
375 new ChromeRenderFrameObserver(render_frame); 380 new ChromeRenderFrameObserver(render_frame);
376 381
377 ContentSettingsObserver* content_settings = 382 ContentSettingsObserver* content_settings =
378 new ContentSettingsObserver(render_frame, extension_dispatcher_.get()); 383 new ContentSettingsObserver(render_frame, extension_dispatcher_.get());
(...skipping 1053 matching lines...) Expand 10 before | Expand all | Expand 10 after
1432 CommandLine* command_line = CommandLine::ForCurrentProcess(); 1437 CommandLine* command_line = CommandLine::ForCurrentProcess();
1433 return !command_line->HasSwitch(extensions::switches::kExtensionProcess); 1438 return !command_line->HasSwitch(extensions::switches::kExtensionProcess);
1434 } 1439 }
1435 1440
1436 blink::WebWorkerPermissionClientProxy* 1441 blink::WebWorkerPermissionClientProxy*
1437 ChromeContentRendererClient::CreateWorkerPermissionClientProxy( 1442 ChromeContentRendererClient::CreateWorkerPermissionClientProxy(
1438 content::RenderFrame* render_frame, 1443 content::RenderFrame* render_frame,
1439 blink::WebFrame* frame) { 1444 blink::WebFrame* frame) {
1440 return new WorkerPermissionClientProxy(render_frame, frame); 1445 return new WorkerPermissionClientProxy(render_frame, frame);
1441 } 1446 }
OLDNEW
« no previous file with comments | « chrome/chrome_browser.gypi ('k') | chrome_elf/chrome_elf.def » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698