Skip to content

Commit

Permalink
Fix names of arguments to SimpleEntryImpl::ChecksumOperationComplete
Browse files Browse the repository at this point in the history
The header had them reversed compared to the implementation
(https://cs.chromium.org/chromium/src/net/disk_cache/simple/simple_entry_impl.cc?rcl=7f44763d0280f85ef331e31f2ea9dd93b3bf6ed3&l=1350)

Also remove abbreviation orig_ -> original_

(and the callers). No executable effect, just makes reading the
code a little easier.

Review-Url: https://codereview.chromium.org/2808763003
Cr-Commit-Position: refs/heads/master@{#463674}
  • Loading branch information
morlovich authored and Commit bot committed Apr 11, 2017
1 parent 3a1c3c6 commit 9e9daf5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions net/disk_cache/simple/simple_entry_impl.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1347,7 +1347,7 @@ void SimpleEntryImpl::DoomOperationComplete(
}

void SimpleEntryImpl::ChecksumOperationComplete(
int orig_result,
int original_result,
int stream_index,
const CompletionCallback& completion_callback,
std::unique_ptr<int> result) {
Expand All @@ -1362,8 +1362,8 @@ void SimpleEntryImpl::ChecksumOperationComplete(
}

if (*result == net::OK) {
*result = orig_result;
if (orig_result >= 0)
*result = original_result;
if (original_result >= 0)
RecordReadResult(cache_type_, READ_RESULT_SUCCESS);
else
RecordReadResult(cache_type_, READ_RESULT_SYNC_READ_FAILURE);
Expand Down
4 changes: 2 additions & 2 deletions net/disk_cache/simple/simple_entry_impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -280,8 +280,8 @@ class NET_EXPORT_PRIVATE SimpleEntryImpl : public Entry,
// Called after validating the checksums on an entry. Passes through the
// original result if successful, propagates the error if the checksum does
// not validate.
void ChecksumOperationComplete(int stream_index,
int orig_result,
void ChecksumOperationComplete(int original_result,
int stream_index,
const CompletionCallback& completion_callback,
std::unique_ptr<int> result);

Expand Down

0 comments on commit 9e9daf5

Please sign in to comment.