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

Commit 6c87df8b authored by Victor Chang's avatar Victor Chang
Browse files

Avoid NoSuchMethodError of List.removeLast() on 24Q2

It's a temporary problem on 24Q2 before the new API lands on 24Q3.
In this CL, the callsite is fixed to avoid calling the API that doesn't
exist on 24Q2.

This CL tries to fix the problem caused between mainline and the new flag system.

Bug: 326109524
Test: m tracinglib-platform
Change-Id: I5e7c5b2d965fa37b844ae8df415f5597578323d0
parent bb969804
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -95,7 +95,7 @@ internal class TraceData : TraceStatus {
     */
    @PublishedApi
    internal fun endSpan(id: Int) {
        val v = slices.removeLast()
        val v = slices.removeAt(slices.lastIndex)
        if (v.id != id) {
            if (STRICT_MODE) {
                throw IllegalArgumentException(MISMATCHED_TRACE_ERROR_MESSAGE)