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 #include "chrome/browser/component_updater/component_updater_utils.h" | 5 #include "chrome/browser/component_updater/component_updater_utils.h" |
6 #include "base/guid.h" | 6 #include "base/guid.h" |
7 #include "base/strings/stringprintf.h" | 7 #include "base/strings/stringprintf.h" |
8 #include "base/sys_info.h" | 8 #include "base/sys_info.h" |
9 #include "base/win/windows_version.h" | 9 #include "base/win/windows_version.h" |
10 #include "chrome/common/chrome_version_info.h" | 10 #include "chrome/common/chrome_version_info.h" |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
95 // Network errors are small negative numbers. | 95 // Network errors are small negative numbers. |
96 const int error = fetcher.GetStatus().error(); | 96 const int error = fetcher.GetStatus().error(); |
97 return error ? error : -1; | 97 return error ? error : -1; |
98 } | 98 } |
99 | 99 |
100 default: | 100 default: |
101 return -1; | 101 return -1; |
102 } | 102 } |
103 } | 103 } |
104 | 104 |
| 105 |
| 106 bool IsHttpServerError(int status_code) { |
| 107 return 500 <= status_code && status_code < 600; |
| 108 } |
| 109 |
105 } // namespace component_updater | 110 } // namespace component_updater |
106 | 111 |
OLD | NEW |