OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // Error codes reported by self tests or to UMA. | 5 // Error codes reported by self tests or to UMA. |
6 | 6 |
7 #ifndef NET_DISK_CACHE_ERRORS_H__ | 7 #ifndef NET_DISK_CACHE_ERRORS_H__ |
8 #define NET_DISK_CACHE_ERRORS_H__ | 8 #define NET_DISK_CACHE_ERRORS_H__ |
9 | 9 |
10 namespace disk_cache { | 10 namespace disk_cache { |
11 | 11 |
12 enum { | 12 enum { |
13 ERR_NO_ERROR = 0, | 13 ERR_NO_ERROR = 0, |
14 ERR_INIT_FAILED = -1, | 14 ERR_INIT_FAILED = -1, |
15 ERR_INVALID_TAIL = -2, | 15 ERR_INVALID_TAIL = -2, |
16 ERR_INVALID_HEAD = -3, | 16 ERR_INVALID_HEAD = -3, |
17 ERR_INVALID_PREV = -4, | 17 ERR_INVALID_PREV = -4, |
18 ERR_INVALID_NEXT = -5, | 18 ERR_INVALID_NEXT = -5, |
19 ERR_INVALID_ENTRY = -6, | 19 ERR_INVALID_ENTRY = -6, |
20 ERR_INVALID_ADDRESS = -7, | 20 ERR_INVALID_ADDRESS = -7, |
21 ERR_INVALID_LINKS = -8, | 21 ERR_INVALID_LINKS = -8, |
22 ERR_NUM_ENTRIES_MISMATCH = -9, | 22 ERR_NUM_ENTRIES_MISMATCH = -9, |
23 ERR_READ_FAILURE = -10, | 23 ERR_READ_FAILURE = -10, |
24 ERR_PREVIOUS_CRASH = -11, | 24 ERR_PREVIOUS_CRASH = -11, |
25 ERR_STORAGE_ERROR = -12, | 25 ERR_STORAGE_ERROR = -12, |
26 ERR_INVALID_MASK = -13, | 26 ERR_INVALID_MASK = -13, |
27 ERR_CACHE_DOOMED = -14, // Not really an error condition. | 27 ERR_CACHE_DOOMED = -14, // Not really an error condition. |
28 ERR_CACHE_CREATED = -15 // Not really an error condition. | 28 ERR_CACHE_CREATED = -15, // Not really an error condition. |
| 29 ERR_PENDING = -16, // Not really an error condition. |
| 30 ERR_OPERATION_FAILED = -17, |
| 31 ERR_WRITE_FAILURE = -18 |
29 }; | 32 }; |
30 | 33 |
31 } // namespace disk_cache | 34 } // namespace disk_cache |
32 | 35 |
33 #endif // NET_DISK_CACHE_ERRORS_H__ | 36 #endif // NET_DISK_CACHE_ERRORS_H__ |
OLD | NEW |