| OLD | NEW |
| 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 #ifndef CHROME_BROWSER_CRASH_HANDLER_HOST_LINUX_H_ | 5 #ifndef COMPONENTS_BREAKPAD_BROWSER_CRASH_HANDLER_HOST_LINUX_H_ |
| 6 #define CHROME_BROWSER_CRASH_HANDLER_HOST_LINUX_H_ | 6 #define COMPONENTS_BREAKPAD_BROWSER_CRASH_HANDLER_HOST_LINUX_H_ |
| 7 | 7 |
| 8 #include <sys/types.h> | 8 #include <sys/types.h> |
| 9 | 9 |
| 10 #include <string> | 10 #include <string> |
| 11 | 11 |
| 12 #include "base/compiler_specific.h" | 12 #include "base/compiler_specific.h" |
| 13 #include "base/files/file_path.h" | 13 #include "base/files/file_path.h" |
| 14 #include "base/memory/scoped_ptr.h" | 14 #include "base/memory/scoped_ptr.h" |
| 15 #include "base/message_loop/message_loop.h" | 15 #include "base/message_loop/message_loop.h" |
| 16 #include "base/threading/sequenced_worker_pool.h" | 16 #include "base/threading/sequenced_worker_pool.h" |
| 17 | 17 |
| 18 struct BreakpadInfo; | |
| 19 | |
| 20 namespace base { | 18 namespace base { |
| 21 class Thread; | 19 class Thread; |
| 22 } | 20 } |
| 23 | 21 |
| 22 namespace breakpad { |
| 23 |
| 24 struct BreakpadInfo; |
| 25 |
| 24 // This is the host for processes which run breakpad inside the sandbox on | 26 // This is the host for processes which run breakpad inside the sandbox on |
| 25 // Linux or Android. We perform the crash dump from the browser because it | 27 // Linux or Android. We perform the crash dump from the browser because it |
| 26 // allows us to be outside the sandbox. | 28 // allows us to be outside the sandbox. |
| 27 // | 29 // |
| 28 // Processes signal that they need to be dumped by sending a datagram over a | 30 // Processes signal that they need to be dumped by sending a datagram over a |
| 29 // UNIX domain socket. All processes of the same type share the client end of | 31 // UNIX domain socket. All processes of the same type share the client end of |
| 30 // this socket which is installed in their descriptor table before exec. | 32 // this socket which is installed in their descriptor table before exec. |
| 31 class CrashHandlerHostLinux : public base::MessageLoopForIO::Watcher, | 33 class CrashHandlerHostLinux : public base::MessageLoopForIO::Watcher, |
| 32 public base::MessageLoop::DestructionObserver { | 34 public base::MessageLoop::DestructionObserver { |
| 33 public: | 35 public: |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 83 // by other tasks. | 85 // by other tasks. |
| 84 base::SequencedWorkerPool::SequenceToken worker_pool_token_; | 86 base::SequencedWorkerPool::SequenceToken worker_pool_token_; |
| 85 | 87 |
| 86 #if defined(ADDRESS_SANITIZER) | 88 #if defined(ADDRESS_SANITIZER) |
| 87 char* asan_report_str_; | 89 char* asan_report_str_; |
| 88 #endif | 90 #endif |
| 89 | 91 |
| 90 DISALLOW_COPY_AND_ASSIGN(CrashHandlerHostLinux); | 92 DISALLOW_COPY_AND_ASSIGN(CrashHandlerHostLinux); |
| 91 }; | 93 }; |
| 92 | 94 |
| 93 #endif // CHROME_BROWSER_CRASH_HANDLER_HOST_LINUX_H_ | 95 } // namespace breakpad |
| 96 |
| 97 #endif // COMPONENTS_BREAKPAD_BROWSER_CRASH_HANDLER_HOST_LINUX_H_ |
| OLD | NEW |