| 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 #include "net/disk_cache/blockfile/sparse_control.h" | 5 #include "net/disk_cache/blockfile/sparse_control.h" |
| 6 | 6 |
| 7 #include <stdint.h> | 7 #include <stdint.h> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/format_macros.h" | 10 #include "base/format_macros.h" |
| 11 #include "base/location.h" | 11 #include "base/location.h" |
| 12 #include "base/logging.h" | 12 #include "base/logging.h" |
| 13 #include "base/macros.h" | 13 #include "base/macros.h" |
| 14 #include "base/single_thread_task_runner.h" | 14 #include "base/single_thread_task_runner.h" |
| 15 #include "base/strings/string_util.h" | 15 #include "base/strings/string_util.h" |
| 16 #include "base/strings/stringprintf.h" | 16 #include "base/strings/stringprintf.h" |
| 17 #include "base/threading/thread_task_runner_handle.h" | 17 #include "base/threading/thread_task_runner_handle.h" |
| 18 #include "base/time/time.h" | 18 #include "base/time/time.h" |
| 19 #include "net/base/io_buffer.h" | 19 #include "net/base/io_buffer.h" |
| 20 #include "net/base/net_errors.h" | 20 #include "net/base/net_errors.h" |
| 21 #include "net/disk_cache/blockfile/backend_impl.h" | 21 #include "net/disk_cache/blockfile/backend_impl.h" |
| 22 #include "net/disk_cache/blockfile/entry_impl.h" | 22 #include "net/disk_cache/blockfile/entry_impl.h" |
| 23 #include "net/disk_cache/blockfile/file.h" | 23 #include "net/disk_cache/blockfile/file.h" |
| 24 #include "net/disk_cache/net_log_parameters.h" | 24 #include "net/disk_cache/net_log_parameters.h" |
| 25 #include "net/log/net_log.h" |
| 25 #include "net/log/net_log_event_type.h" | 26 #include "net/log/net_log_event_type.h" |
| 27 #include "net/log/net_log_with_source.h" |
| 26 | 28 |
| 27 using base::Time; | 29 using base::Time; |
| 28 | 30 |
| 29 namespace { | 31 namespace { |
| 30 | 32 |
| 31 // Stream of the sparse data index. | 33 // Stream of the sparse data index. |
| 32 const int kSparseIndex = 2; | 34 const int kSparseIndex = 2; |
| 33 | 35 |
| 34 // Stream of the sparse data. | 36 // Stream of the sparse data. |
| 35 const int kSparseData = 1; | 37 const int kSparseData = 1; |
| (...skipping 866 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 902 CompletionCallback cb = abort_callbacks_[i]; | 904 CompletionCallback cb = abort_callbacks_[i]; |
| 903 if (i == abort_callbacks_.size() - 1) | 905 if (i == abort_callbacks_.size() - 1) |
| 904 abort_callbacks_.clear(); | 906 abort_callbacks_.clear(); |
| 905 | 907 |
| 906 entry_->Release(); // Don't touch object after this line. | 908 entry_->Release(); // Don't touch object after this line. |
| 907 cb.Run(net::OK); | 909 cb.Run(net::OK); |
| 908 } | 910 } |
| 909 } | 911 } |
| 910 | 912 |
| 911 } // namespace disk_cache | 913 } // namespace disk_cache |
| OLD | NEW |