Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 412673d0 authored by Pirama Arumuga Nainar's avatar Pirama Arumuga Nainar
Browse files

Fix type of comparison operator

Bug: 411656971

Use std::greater<uint32_t> when sorting a vector of uint32_t.

Test: presubmit
Change-Id: I97b16a7caf926106e7bac26d56e2f0b631c97669
parent d27e3c4c
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -322,7 +322,7 @@ bool CowReader::PrepMergeOps() {
    if (reader_flag_ == ReaderFlags::USERSPACE_MERGE) {
        std::sort(other_ops.begin(), other_ops.end());
    } else {
        std::sort(other_ops.begin(), other_ops.end(), std::greater<int>());
        std::sort(other_ops.begin(), other_ops.end(), std::greater<uint32_t>());
    }

    merge_op_blocks.insert(merge_op_blocks.end(), other_ops.begin(), other_ops.end());