Commit 5278b689 authored by Uwe Schulzweida's avatar Uwe Schulzweida

Fix clang warning: result of comparison of constant 128 with expression of...

Fix clang warning: result of comparison of constant 128 with expression of type 'std::vector<char>::value_type is always true.
parent eac2b367
Pipeline #5583 passed with stages
in 14 minutes and 47 seconds
...@@ -413,7 +413,7 @@ void check_vmask(std::vector<char> vmask) ...@@ -413,7 +413,7 @@ void check_vmask(std::vector<char> vmask)
constexpr int max_vals = 128; constexpr int max_vals = 128;
size_t vm[max_vals] = { 0 }; size_t vm[max_vals] = { 0 };
const auto size = vmask.size(); const auto size = vmask.size();
for (size_t i = 0; i < size; ++i) if (vmask[i] >= 0 && vmask[i] < max_vals) vm[(int)vmask[i]]++; for (size_t i = 0; i < size; ++i) if (vmask[i] >= 0) vm[(int)vmask[i]]++;
for (int i = 0; i < max_vals; ++i) if (vm[i]) cdoPrint("Number of source values: %d --> %zu/%zu", i, vm[i], size); for (int i = 0; i < max_vals; ++i) if (vm[i]) cdoPrint("Number of source values: %d --> %zu/%zu", i, vm[i], size);
size_t sum = 0; size_t sum = 0;
for (int i = 1; i < max_vals; ++i) sum += vm[i]; for (int i = 1; i < max_vals; ++i) sum += vm[i];
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment