Skip to content
Snippets Groups Projects
Commit c94cf7d4 authored by Shaju Mathew's avatar Shaju Mathew
Browse files

Removing unused counters.

Bug: N/A
Test: Treehugger
Change-Id: I058b0e550c7ed9197934f2bbda1146e776324934
parent 39c4a124
No related branches found
No related tags found
No related merge requests found
......@@ -182,7 +182,7 @@ static inline IncFsSize verityTreeSizeForFile(IncFsSize fileSize) {
auto block_count = 1 + (fileSize - 1) / INCFS_DATA_FILE_BLOCK_SIZE;
auto hash_block_count = block_count;
for (auto i = 0; hash_block_count > 1; i++) {
while (hash_block_count > 1) {
hash_block_count = (hash_block_count + hash_per_block - 1) / hash_per_block;
total_tree_block_count += hash_block_count;
}
......@@ -468,7 +468,6 @@ private:
borrowed_fd incomingFd, bool waitOnEof, std::vector<char>* buffer,
std::vector<IncFsDataBlock>* blocks) {
IncFsSize remaining = size;
IncFsSize totalSize = 0;
IncFsBlockIndex blockIdx = 0;
while (remaining > 0) {
constexpr auto capacity = BUFFER_SIZE;
......@@ -502,7 +501,6 @@ private:
buffer->resize(size + read);
remaining -= read;
totalSize += read;
}
if (!buffer->empty() && !flashToIncFs(incfsFd, kind, true, &blockIdx, buffer, blocks)) {
return false;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment