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/breakpad/app/breakpad_linux.h" | 8 #include "components/breakpad/app/breakpad_linux.h" |
9 | 9 |
10 #include <fcntl.h> | 10 #include <fcntl.h> |
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
199 while (len > 0 && str[len - 1] == ' ') { | 199 while (len > 0 && str[len - 1] == ' ') { |
200 len--; | 200 len--; |
201 } | 201 } |
202 return len; | 202 return len; |
203 } | 203 } |
204 | 204 |
205 void SetClientIdFromCommandLine(const CommandLine& command_line) { | 205 void SetClientIdFromCommandLine(const CommandLine& command_line) { |
206 // Get the guid from the command line switch. | 206 // Get the guid from the command line switch. |
207 std::string switch_value = | 207 std::string switch_value = |
208 command_line.GetSwitchValueASCII(switches::kEnableCrashReporter); | 208 command_line.GetSwitchValueASCII(switches::kEnableCrashReporter); |
209 GetBreakpadClient()->SetClientID(switch_value); | 209 GetBreakpadClient()->SetBreakpadClientIdFromGUID(switch_value); |
210 } | 210 } |
211 | 211 |
212 // MIME substrings. | 212 // MIME substrings. |
213 #if defined(OS_CHROMEOS) | 213 #if defined(OS_CHROMEOS) |
214 const char g_sep[] = ":"; | 214 const char g_sep[] = ":"; |
215 #endif | 215 #endif |
216 const char g_rn[] = "\r\n"; | 216 const char g_rn[] = "\r\n"; |
217 const char g_form_data_msg[] = "Content-Disposition: form-data; name=\""; | 217 const char g_form_data_msg[] = "Content-Disposition: form-data; name=\""; |
218 const char g_quote_msg[] = "\""; | 218 const char g_quote_msg[] = "\""; |
219 const char g_dashdash_msg[] = "--"; | 219 const char g_dashdash_msg[] = "--"; |
(...skipping 1386 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1606 } | 1606 } |
1607 } | 1607 } |
1608 } | 1608 } |
1609 #endif // OS_ANDROID | 1609 #endif // OS_ANDROID |
1610 | 1610 |
1611 bool IsCrashReporterEnabled() { | 1611 bool IsCrashReporterEnabled() { |
1612 return g_is_crash_reporter_enabled; | 1612 return g_is_crash_reporter_enabled; |
1613 } | 1613 } |
1614 | 1614 |
1615 } // namespace breakpad | 1615 } // namespace breakpad |
OLD | NEW |