| 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 // For linux_syscall_support.h. This makes it safe to call embedded system | 5 // For linux_syscall_support.h. This makes it safe to call embedded system |
| 6 // calls when in seccomp mode. | 6 // calls when in seccomp mode. |
| 7 | 7 |
| 8 #include "chrome/app/breakpad_linux.h" | 8 #include "chrome/app/breakpad_linux.h" |
| 9 | 9 |
| 10 #include <fcntl.h> | 10 #include <fcntl.h> |
| 11 #include <poll.h> | 11 #include <poll.h> |
| 12 #include <signal.h> | 12 #include <signal.h> |
| 13 #include <stdlib.h> | 13 #include <stdlib.h> |
| 14 #include <sys/socket.h> | 14 #include <sys/socket.h> |
| 15 #include <sys/time.h> | 15 #include <sys/time.h> |
| 16 #include <sys/types.h> | 16 #include <sys/types.h> |
| 17 #include <sys/uio.h> | 17 #include <sys/uio.h> |
| 18 #include <sys/wait.h> | 18 #include <sys/wait.h> |
| 19 #include <time.h> | 19 #include <time.h> |
| 20 #include <unistd.h> | 20 #include <unistd.h> |
| 21 | 21 |
| 22 #include <algorithm> | 22 #include <algorithm> |
| 23 #include <string> | 23 #include <string> |
| 24 | 24 |
| 25 #include "base/base_switches.h" |
| 25 #include "base/command_line.h" | 26 #include "base/command_line.h" |
| 26 #include "base/debug/crash_logging.h" | 27 #include "base/debug/crash_logging.h" |
| 27 #include "base/files/file_path.h" | 28 #include "base/files/file_path.h" |
| 28 #include "base/linux_util.h" | 29 #include "base/linux_util.h" |
| 29 #include "base/path_service.h" | 30 #include "base/path_service.h" |
| 30 #include "base/platform_file.h" | 31 #include "base/platform_file.h" |
| 31 #include "base/posix/eintr_wrapper.h" | 32 #include "base/posix/eintr_wrapper.h" |
| 32 #include "base/posix/global_descriptors.h" | 33 #include "base/posix/global_descriptors.h" |
| 33 #include "base/process_util.h" | 34 #include "base/process_util.h" |
| 34 #include "base/strings/string_util.h" | 35 #include "base/strings/string_util.h" |
| 35 #include "breakpad/src/client/linux/handler/exception_handler.h" | 36 #include "breakpad/src/client/linux/handler/exception_handler.h" |
| 36 #include "breakpad/src/client/linux/minidump_writer/directory_reader.h" | 37 #include "breakpad/src/client/linux/minidump_writer/directory_reader.h" |
| 37 #include "breakpad/src/common/linux/linux_libc_support.h" | 38 #include "breakpad/src/common/linux/linux_libc_support.h" |
| 38 #include "breakpad/src/common/memory.h" | 39 #include "breakpad/src/common/memory.h" |
| 39 #include "chrome/app/breakpad_linux_impl.h" | 40 #include "chrome/app/breakpad_linux_impl.h" |
| 40 #include "chrome/browser/crash_upload_list.h" | 41 #include "chrome/browser/crash_upload_list.h" |
| 41 #include "chrome/common/child_process_logging.h" | 42 #include "chrome/common/child_process_logging.h" |
| 42 #include "chrome/common/chrome_switches.h" | |
| 43 #include "chrome/common/chrome_version_info_posix.h" | 43 #include "chrome/common/chrome_version_info_posix.h" |
| 44 #include "chrome/common/crash_keys.h" | 44 #include "chrome/common/crash_keys.h" |
| 45 #include "chrome/common/env_vars.h" | 45 #include "chrome/common/env_vars.h" |
| 46 #include "components/breakpad/breakpad_client.h" | 46 #include "components/breakpad/breakpad_client.h" |
| 47 #include "content/public/common/content_descriptors.h" | 47 #include "content/public/common/content_descriptors.h" |
| 48 #include "content/public/common/content_switches.h" |
| 48 | 49 |
| 49 #if defined(OS_ANDROID) | 50 #if defined(OS_ANDROID) |
| 50 #include <android/log.h> | 51 #include <android/log.h> |
| 51 #include <sys/stat.h> | 52 #include <sys/stat.h> |
| 52 | 53 |
| 53 #include "base/android/build_info.h" | 54 #include "base/android/build_info.h" |
| 54 #include "base/android/path_utils.h" | 55 #include "base/android/path_utils.h" |
| 55 #include "chrome/common/descriptors_android.h" | 56 #include "chrome/common/descriptors_android.h" |
| 56 #endif | 57 #endif |
| 57 #include "third_party/lss/linux_syscall_support.h" | 58 #include "third_party/lss/linux_syscall_support.h" |
| (...skipping 1659 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1717 } else { | 1718 } else { |
| 1718 EnableNonBrowserCrashDumping(minidump_fd); | 1719 EnableNonBrowserCrashDumping(minidump_fd); |
| 1719 } | 1720 } |
| 1720 } | 1721 } |
| 1721 } | 1722 } |
| 1722 #endif // OS_ANDROID | 1723 #endif // OS_ANDROID |
| 1723 | 1724 |
| 1724 bool IsCrashReporterEnabled() { | 1725 bool IsCrashReporterEnabled() { |
| 1725 return g_is_crash_reporter_enabled; | 1726 return g_is_crash_reporter_enabled; |
| 1726 } | 1727 } |
| OLD | NEW |