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

Commit 1f97004e authored by Brad Hinegardner's avatar Brad Hinegardner Committed by Android (Google) Code Review
Browse files

Merge "User should be able to change clocks without crash" into main

parents ddfbe795 c878feff
Loading
Loading
Loading
Loading
+6 −6
Original line number Diff line number Diff line
@@ -27,14 +27,14 @@ import kotlin.collections.ArrayDeque
 * immediately. This defeats the intention behind [LogBuffer] and should only be used when
 * [LogBuffer]s are unavailable in a certain context.
 */
class LogcatOnlyMessageBuffer
@JvmOverloads
constructor(
class LogcatOnlyMessageBuffer(
    private val targetLogLevel: LogLevel,
    private val maxMessageCount: Int = DEFAULT_MESSAGE_MAX_COUNT,
    private val maxMessageCount: Int,
): MessageBuffer {
    private val messages = ArrayDeque<LogMessageImpl>(maxMessageCount)

    constructor(targetLogLevel: LogLevel) : this(targetLogLevel, DEFAULT_MESSAGE_MAX_COUNT)

    override fun obtain(
        tag: String,
        level: LogLevel,
@@ -65,6 +65,6 @@ constructor(
    }

    companion object {
        val DEFAULT_MESSAGE_MAX_COUNT = 4
        private const val DEFAULT_MESSAGE_MAX_COUNT = 4
    }
}