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

Commit c44cc05c authored by Mark Fasheh's avatar Mark Fasheh
Browse files

DeliQueue: use correct MessageCompare variables

removeAllMessages() and removeAllFutureMessages() should use their
respective matchers.

Test: atest MessageQueueTest
Bug: 421623328
Flag: EXEMPT new data structure isn't used yet; usages will be flagged.
Change-Id: I6bd7c7874bdee932f196a88753ae33ea9e310ef2
parent 9564d9c7
Loading
Loading
Loading
Loading
+2 −4
Original line number Diff line number Diff line
@@ -877,13 +877,11 @@ public final class MessageQueue {
    }

    private void removeAllMessages() {
        mStack.moveMatchingToFreelist(sMatchHandlerAndObjectEquals, null, -1, null, null,
                0);
        mStack.moveMatchingToFreelist(sMatchAllMessages, null, -1, null, null, 0);
    }

    private void removeAllFutureMessages(long when) {
        mStack.moveMatchingToFreelist(sMatchHandlerAndObjectEquals, null, -1, null, null,
                when);
        mStack.moveMatchingToFreelist(sMatchAllFutureMessages, null, -1, null, null, when);
    }

    /**