OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "components/crash/content/app/breakpad_linux.h" | 8 #include "components/crash/content/app/breakpad_linux.h" |
9 | 9 |
10 #include <fcntl.h> | 10 #include <fcntl.h> |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
69 #define FSTAT_FUNC fstat | 69 #define FSTAT_FUNC fstat |
70 #else | 70 #else |
71 #define STAT_STRUCT struct kernel_stat | 71 #define STAT_STRUCT struct kernel_stat |
72 #define FSTAT_FUNC sys_fstat | 72 #define FSTAT_FUNC sys_fstat |
73 #endif | 73 #endif |
74 | 74 |
75 // Some versions of gcc are prone to warn about unused return values. In cases | 75 // Some versions of gcc are prone to warn about unused return values. In cases |
76 // where we either a) know the call cannot fail, or b) there is nothing we | 76 // where we either a) know the call cannot fail, or b) there is nothing we |
77 // can do when a call fails, we mark the return code as ignored. This avoids | 77 // can do when a call fails, we mark the return code as ignored. This avoids |
78 // spurious compiler warnings. | 78 // spurious compiler warnings. |
79 #define IGNORE_RET(x) do { if (x); } while (0) | 79 #define IGNORE_RET(x) ignore_result(x) |
80 | 80 |
81 using crash_reporter::GetCrashReporterClient; | 81 using crash_reporter::GetCrashReporterClient; |
82 using google_breakpad::ExceptionHandler; | 82 using google_breakpad::ExceptionHandler; |
83 using google_breakpad::MinidumpDescriptor; | 83 using google_breakpad::MinidumpDescriptor; |
84 | 84 |
85 namespace breakpad { | 85 namespace breakpad { |
86 | 86 |
87 namespace { | 87 namespace { |
88 | 88 |
89 #if !defined(OS_CHROMEOS) | 89 #if !defined(OS_CHROMEOS) |
(...skipping 1776 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1866 const std::string& gpu_fingerprint) { | 1866 const std::string& gpu_fingerprint) { |
1867 g_microdump_info.Get().SetGpuFingerprint(gpu_fingerprint); | 1867 g_microdump_info.Get().SetGpuFingerprint(gpu_fingerprint); |
1868 } | 1868 } |
1869 #endif // OS_ANDROID | 1869 #endif // OS_ANDROID |
1870 | 1870 |
1871 bool IsCrashReporterEnabled() { | 1871 bool IsCrashReporterEnabled() { |
1872 return g_is_crash_reporter_enabled; | 1872 return g_is_crash_reporter_enabled; |
1873 } | 1873 } |
1874 | 1874 |
1875 } // namespace breakpad | 1875 } // namespace breakpad |
OLD | NEW |