| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "components/nacl/renderer/nexe_load_manager.h" | 5 #include "components/nacl/renderer/nexe_load_manager.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/containers/scoped_ptr_hash_map.h" | 8 #include "base/containers/scoped_ptr_hash_map.h" |
| 9 #include "base/lazy_instance.h" | 9 #include "base/lazy_instance.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 88 | 88 |
| 89 NexeLoadManager::NexeLoadManager( | 89 NexeLoadManager::NexeLoadManager( |
| 90 PP_Instance pp_instance) | 90 PP_Instance pp_instance) |
| 91 : pp_instance_(pp_instance), | 91 : pp_instance_(pp_instance), |
| 92 nacl_ready_state_(PP_NACL_READY_STATE_UNSENT), | 92 nacl_ready_state_(PP_NACL_READY_STATE_UNSENT), |
| 93 nexe_error_reported_(false), | 93 nexe_error_reported_(false), |
| 94 is_installed_(false), | 94 is_installed_(false), |
| 95 exit_status_(-1), | 95 exit_status_(-1), |
| 96 nexe_size_(0), | 96 nexe_size_(0), |
| 97 plugin_instance_(content::PepperPluginInstance::Get(pp_instance)), | 97 plugin_instance_(content::PepperPluginInstance::Get(pp_instance)), |
| 98 nonsfi_(false), | |
| 99 crash_info_shmem_handle_(base::SharedMemory::NULLHandle()), | 98 crash_info_shmem_handle_(base::SharedMemory::NULLHandle()), |
| 100 weak_factory_(this) { | 99 weak_factory_(this) { |
| 101 set_exit_status(-1); | 100 set_exit_status(-1); |
| 102 SetLastError(""); | 101 SetLastError(""); |
| 103 HistogramEnumerateOsArch(GetSandboxArch()); | 102 HistogramEnumerateOsArch(GetSandboxArch()); |
| 104 if (plugin_instance_) { | 103 if (plugin_instance_) { |
| 105 plugin_base_url_ = | 104 plugin_base_url_ = |
| 106 plugin_instance_->GetContainer()->element().document().url(); | 105 plugin_instance_->GetContainer()->element().document().url(); |
| 107 } | 106 } |
| 108 } | 107 } |
| (...skipping 361 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 470 // to provide error handling. | 469 // to provide error handling. |
| 471 } | 470 } |
| 472 | 471 |
| 473 void NexeLoadManager::CopyCrashLogToJsConsole(const std::string& crash_log) { | 472 void NexeLoadManager::CopyCrashLogToJsConsole(const std::string& crash_log) { |
| 474 base::StringTokenizer t(crash_log, "\n"); | 473 base::StringTokenizer t(crash_log, "\n"); |
| 475 while (t.GetNext()) | 474 while (t.GetNext()) |
| 476 LogToConsole(t.token()); | 475 LogToConsole(t.token()); |
| 477 } | 476 } |
| 478 | 477 |
| 479 } // namespace nacl | 478 } // namespace nacl |
| OLD | NEW |