OLD | NEW |
1 // Copyright (c) 2010 The Chromium OS Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium OS 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 CHROMEOS_PLATFORM_UPDATE_ENGINE_UPDATE_ATTEMPTER_H__ | 5 #ifndef CHROMEOS_PLATFORM_UPDATE_ENGINE_UPDATE_ATTEMPTER_H__ |
6 #define CHROMEOS_PLATFORM_UPDATE_ENGINE_UPDATE_ATTEMPTER_H__ | 6 #define CHROMEOS_PLATFORM_UPDATE_ENGINE_UPDATE_ATTEMPTER_H__ |
7 | 7 |
8 #include <time.h> | 8 #include <time.h> |
9 | 9 |
10 #include <tr1/memory> | 10 #include <tr1/memory> |
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
151 | 151 |
152 // Resets the process priority to normal and destroys any scheduled timeout | 152 // Resets the process priority to normal and destroys any scheduled timeout |
153 // sources. | 153 // sources. |
154 void CleanupPriorityManagement(); | 154 void CleanupPriorityManagement(); |
155 | 155 |
156 // The process priority timeout source callback sets the current priority to | 156 // The process priority timeout source callback sets the current priority to |
157 // normal. Returns false so that GLib destroys the timeout source. | 157 // normal. Returns false so that GLib destroys the timeout source. |
158 static gboolean StaticManagePriorityCallback(gpointer data); | 158 static gboolean StaticManagePriorityCallback(gpointer data); |
159 bool ManagePriorityCallback(); | 159 bool ManagePriorityCallback(); |
160 | 160 |
| 161 // Callback to start the action processor. |
| 162 static gboolean StaticStartProcessing(gpointer data); |
| 163 |
161 // Checks if a full update is needed and forces it by updating the Omaha | 164 // Checks if a full update is needed and forces it by updating the Omaha |
162 // request params. | 165 // request params. |
163 void DisableDeltaUpdateIfNeeded(); | 166 void DisableDeltaUpdateIfNeeded(); |
164 | 167 |
165 // If this was a delta update attempt that failed, count it so that a full | 168 // If this was a delta update attempt that failed, count it so that a full |
166 // update can be tried when needed. | 169 // update can be tried when needed. |
167 void MarkDeltaUpdateFailure(); | 170 void MarkDeltaUpdateFailure(); |
168 | 171 |
169 ProxyResolver* GetProxyResolver() { | 172 ProxyResolver* GetProxyResolver() { |
170 return obeying_proxies_ ? | 173 return obeying_proxies_ ? |
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
236 // Our two proxy resolvers | 239 // Our two proxy resolvers |
237 DirectProxyResolver direct_proxy_resolver_; | 240 DirectProxyResolver direct_proxy_resolver_; |
238 ChromeBrowserProxyResolver chrome_proxy_resolver_; | 241 ChromeBrowserProxyResolver chrome_proxy_resolver_; |
239 | 242 |
240 DISALLOW_COPY_AND_ASSIGN(UpdateAttempter); | 243 DISALLOW_COPY_AND_ASSIGN(UpdateAttempter); |
241 }; | 244 }; |
242 | 245 |
243 } // namespace chromeos_update_engine | 246 } // namespace chromeos_update_engine |
244 | 247 |
245 #endif // CHROMEOS_PLATFORM_UPDATE_ENGINE_UPDATE_ATTEMPTER_H__ | 248 #endif // CHROMEOS_PLATFORM_UPDATE_ENGINE_UPDATE_ATTEMPTER_H__ |
OLD | NEW |