Fix for cppcheck issue:
[src/osd/ECUtil.h:61]: (style) Clarify calculation
precedence for '%' and '?'.
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
return offset - (offset % stripe_width);
}
uint64_t logical_to_next_stripe_offset(uint64_t offset) const {
- return offset % stripe_width ?
- offset - (offset % stripe_width) + stripe_width :
- offset;
+ return ((offset % stripe_width) ?
+ (offset - (offset % stripe_width) + stripe_width) :
+ offset);
}
uint64_t aligned_logical_offset_to_chunk_offset(uint64_t offset) const {
assert(offset % stripe_width == 0);