Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 // Note that the embedder is welcome to persist these values across | 5 // Note that the embedder is welcome to persist these values across |
| 6 // invocations of the browser, and possibly across browser versions. | 6 // invocations of the browser, and possibly across browser versions. |
| 7 // Thus individual errors may be deprecated and new errors added, but | 7 // Thus individual errors may be deprecated and new errors added, but |
| 8 // the values of particular errors should not be changed. | 8 // the values of particular errors should not be changed. |
| 9 | 9 |
| 10 // File errors. | 10 // File errors. |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 79 // Server responses. | 79 // Server responses. |
| 80 | 80 |
| 81 // The server indicates that the operation has failed (generic). | 81 // The server indicates that the operation has failed (generic). |
| 82 // "Server Error". | 82 // "Server Error". |
| 83 INTERRUPT_REASON(SERVER_FAILED, 30) | 83 INTERRUPT_REASON(SERVER_FAILED, 30) |
| 84 | 84 |
| 85 // The server does not support range requests. | 85 // The server does not support range requests. |
| 86 // Internal use only: must restart from the beginning. | 86 // Internal use only: must restart from the beginning. |
| 87 INTERRUPT_REASON(SERVER_NO_RANGE, 31) | 87 INTERRUPT_REASON(SERVER_NO_RANGE, 31) |
| 88 | 88 |
| 89 // The download request does not meet the specified precondition. | 89 // Precondition failed. This type of interruption could legitimately occur if a |
| 90 // Internal use only: the file has changed on the server. | 90 // partial download resumption was attempted using a If-Match header. However, |
| 91 INTERRUPT_REASON(SERVER_PRECONDITION, 32) | 91 // the downloads logic no longer uses If-Match headers and instead uses If-Range |
| 92 // headers where a precondition failure is not expected. | |
| 93 // INTERRUPT_REASON(SERVER_PRECONDITION, 32) | |
|
davidben
2015/11/23 17:35:37
Nit: Maybe do
// Obsolete: INTERRUPT_REASON(...)
asanka
2015/11/23 22:01:11
Done. Went with the former.
| |
| 92 | 94 |
| 93 // The server does not have the requested data. | 95 // The server does not have the requested data. |
| 94 // "Unable to get file". | 96 // "Unable to get file". |
| 95 INTERRUPT_REASON(SERVER_BAD_CONTENT, 33) | 97 INTERRUPT_REASON(SERVER_BAD_CONTENT, 33) |
| 96 | 98 |
| 97 // Server didn't authorize access to resource. | 99 // Server didn't authorize access to resource. |
| 98 INTERRUPT_REASON(SERVER_UNAUTHORIZED, 34) | 100 INTERRUPT_REASON(SERVER_UNAUTHORIZED, 34) |
| 99 | 101 |
| 100 // Server certificate problem. | 102 // Server certificate problem. |
| 101 INTERRUPT_REASON(SERVER_CERT_PROBLEM, 35) | 103 INTERRUPT_REASON(SERVER_CERT_PROBLEM, 35) |
| (...skipping 10 matching lines...) Expand all Loading... | |
| 112 // The user shut down the browser. | 114 // The user shut down the browser. |
| 113 // Internal use only: resume pending downloads if possible. | 115 // Internal use only: resume pending downloads if possible. |
| 114 INTERRUPT_REASON(USER_SHUTDOWN, 41) | 116 INTERRUPT_REASON(USER_SHUTDOWN, 41) |
| 115 | 117 |
| 116 | 118 |
| 117 // Crash. | 119 // Crash. |
| 118 | 120 |
| 119 // The browser crashed. | 121 // The browser crashed. |
| 120 // Internal use only: resume pending downloads if possible. | 122 // Internal use only: resume pending downloads if possible. |
| 121 INTERRUPT_REASON(CRASH, 50) | 123 INTERRUPT_REASON(CRASH, 50) |
| OLD | NEW |