diff options
author | erikcorry <erikcorry@chromium.org> | 2015-06-08 04:29:16 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-06-08 11:30:00 +0000 |
commit | c94eff1e7e8b2bd5973d7211c320d9f025c980c1 (patch) | |
tree | b74c21bb58fadc70af46c76fb43d214c494c3766 /content/shell/browser/shell_content_browser_client.h | |
parent | 878d687f2f9ff7d9f6424309d216ee2459886b68 (diff) | |
download | chromium_src-c94eff1e7e8b2bd5973d7211c320d9f025c980c1.zip chromium_src-c94eff1e7e8b2bd5973d7211c320d9f025c980c1.tar.gz chromium_src-c94eff1e7e8b2bd5973d7211c320d9f025c980c1.tar.bz2 |
Allow startup with missing V8 snapshot file.
We want to stop shipping the snapshot file, and instead we want
to generate it on the client. This will reduce the download size.
But since snapshot generation will be asynchronous in a utility
process, it might not be present on the first few runs of the
browser. This means we have to be able to start up without the
snapshot file (just with the natives source file). This CL
fixes Blink to cope with a missing snapshot file (V8 could
already cope).
R=rmcilroy@chromium.org, sky@chromium.org
BUG=
Review URL: https://codereview.chromium.org/1164483003
Cr-Commit-Position: refs/heads/master@{#333258}
Diffstat (limited to 'content/shell/browser/shell_content_browser_client.h')
-rw-r--r-- | content/shell/browser/shell_content_browser_client.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/content/shell/browser/shell_content_browser_client.h b/content/shell/browser/shell_content_browser_client.h index 0dc59b2..fe843a6 100644 --- a/content/shell/browser/shell_content_browser_client.h +++ b/content/shell/browser/shell_content_browser_client.h @@ -46,6 +46,8 @@ class ShellContentBrowserClient : public ContentBrowserClient { bool IsHandledURL(const GURL& url) override; void AppendExtraCommandLineSwitches(base::CommandLine* command_line, int child_process_id) override; + void AppendMappedFileCommandLineSwitches( + base::CommandLine* command_line) override; void OverrideWebkitPrefs(RenderViewHost* render_view_host, WebPreferences* prefs) override; void ResourceDispatcherHostCreated() override; @@ -106,6 +108,8 @@ class ShellContentBrowserClient : public ContentBrowserClient { #if defined(OS_POSIX) && !defined(OS_MACOSX) base::ScopedFD v8_natives_fd_; base::ScopedFD v8_snapshot_fd_; + bool natives_fd_exists() { return v8_natives_fd_ != -1; } + bool snapshot_fd_exists() { return v8_snapshot_fd_ != -1; } #endif base::Closure select_client_certificate_callback_; |