diff options
| author | Peter Varga <pvarga@inf.u-szeged.hu> | 2017-06-07 10:37:04 +0200 |
|---|---|---|
| committer | Peter Varga <pvarga@inf.u-szeged.hu> | 2017-06-09 07:10:33 +0000 |
| commit | 4a23e0462a610f421d22fba38b0f9ba72120ae18 (patch) | |
| tree | 002fa8c0e7ae547339e8d5bb73fe3a2ecf1a2c95 /chromium | |
| parent | f11a845f8596cc23a584f259d78317b66e74fe49 (diff) | |
| download | qtwebengine-chromium-4a23e0462a610f421d22fba38b0f9ba72120ae18.tar.gz | |
Suppress error message on unneeded V8 external startup files
When v8_use_external_startup_data is disabled natives_blob.bin and
snapshot_blob.bin external files are not generated. Skip try to open
them for their file descriptors to suppress "Ignore invalid file" error
messages due to non-existent files.
This change adds back guards removed in
https://codereview.chromium.org/2684433003
Change-Id: I0bb93c0e05df18905083423a84d1e56c22232e4d
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'chromium')
| -rw-r--r-- | chromium/content/browser/child_process_launcher_helper_posix.cc | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/chromium/content/browser/child_process_launcher_helper_posix.cc b/chromium/content/browser/child_process_launcher_helper_posix.cc index f245ef2f83b..666598d43b9 100644 --- a/chromium/content/browser/child_process_launcher_helper_posix.cc +++ b/chromium/content/browser/child_process_launcher_helper_posix.cc @@ -12,6 +12,7 @@ #include "content/browser/file_descriptor_info_impl.h" #include "content/public/browser/content_browser_client.h" #include "content/public/common/content_client.h" +#include "content/public/common/content_descriptor_keys.h" #include "content/public/common/content_descriptors.h" #include "content/public/common/content_switches.h" #include "mojo/edk/embedder/platform_handle.h" @@ -107,6 +108,14 @@ std::unique_ptr<FileDescriptorInfo> CreateDefaultPosixFilesToMap( base::GlobalDescriptors::Key key = kContentDynamicDescriptorStart; service_manager::SharedFileSwitchValueBuilder file_switch_value_builder; for (const auto& key_path_iter : required_files_map) { + +#if !defined(V8_USE_EXTERNAL_STARTUP_DATA) + if (key_path_iter.first == content::kV8NativesDataDescriptor || + key_path_iter.first == content::kV8SnapshotDataDescriptor) { + continue; + } +#endif // !V8_USE_EXTERNAL_STARTUP_DATA + base::MemoryMappedFile::Region region; base::PlatformFile file = OpenFileIfNecessary(key_path_iter.second, ®ion); |
