From 2be76c898c3429b8622b1e47fc59bca0fbaa99ea Mon Sep 17 00:00:00 2001 From: Claude Date: Sat, 9 May 2026 01:40:48 +0000 Subject: [PATCH] fix(quic): resolve dangling KDoc lint errors Move the feedDatagram KDoc below the MAX_QUIC_OFFSET const so it attaches to the function declaration, and merge the duplicate KDoc blocks above TlsResumptionState into a single block. --- .../vitorpamplona/quic/connection/QuicConnectionParser.kt | 7 +++---- .../kotlin/com/vitorpamplona/quic/tls/TlsClient.kt | 7 ++----- 2 files changed, 5 insertions(+), 9 deletions(-) diff --git a/quic/src/commonMain/kotlin/com/vitorpamplona/quic/connection/QuicConnectionParser.kt b/quic/src/commonMain/kotlin/com/vitorpamplona/quic/connection/QuicConnectionParser.kt index bf40b8d1b..08e791029 100644 --- a/quic/src/commonMain/kotlin/com/vitorpamplona/quic/connection/QuicConnectionParser.kt +++ b/quic/src/commonMain/kotlin/com/vitorpamplona/quic/connection/QuicConnectionParser.kt @@ -49,6 +49,9 @@ import com.vitorpamplona.quic.packet.ShortHeaderPacket import com.vitorpamplona.quic.stream.StreamId import com.vitorpamplona.quic.tls.TlsClient +/** RFC 9000 §16: maximum varint value, also the per-stream offset ceiling. */ +private const val MAX_QUIC_OFFSET: Long = (1L shl 62) - 1L + /** * Decode every QUIC packet inside a single inbound UDP datagram and dispatch * its frames to [conn]'s state. @@ -67,10 +70,6 @@ import com.vitorpamplona.quic.tls.TlsClient * under streamsLock so frame-dispatch / stream creation / level state * remains a single critical section. */ - -/** RFC 9000 §16: maximum varint value, also the per-stream offset ceiling. */ -private const val MAX_QUIC_OFFSET: Long = (1L shl 62) - 1L - fun feedDatagram( conn: QuicConnection, datagram: ByteArray, diff --git a/quic/src/commonMain/kotlin/com/vitorpamplona/quic/tls/TlsClient.kt b/quic/src/commonMain/kotlin/com/vitorpamplona/quic/tls/TlsClient.kt index ac204ec20..d6499b640 100644 --- a/quic/src/commonMain/kotlin/com/vitorpamplona/quic/tls/TlsClient.kt +++ b/quic/src/commonMain/kotlin/com/vitorpamplona/quic/tls/TlsClient.kt @@ -668,7 +668,8 @@ interface TlsSecretsListener { * Self-contained state needed to resume a TLS 1.3 session via PSK on the * next connection. Produced by the TLS layer when a NewSessionTicket * arrives; consumed by a fresh [TlsClient] via its `resumption` - * constructor argument. + * constructor argument. Lets the client offer RFC 8446 PSK-resumption + + * RFC 9001 §4.6 0-RTT on the next connection. * * Why store all this rather than just the ticket: the PSK derivation * binds to a specific cipher suite (32-byte hash for our SHA-256 suites) @@ -676,10 +677,6 @@ interface TlsSecretsListener { * obfuscation arithmetic on the next connection needs both * [ticketAgeAdd] and [issuedAtMillis] to compute the obfuscated_ticket_age * the server expects. - */ -/** - * Cached state from a prior TLS handshake that lets the client offer - * RFC 8446 PSK-resumption + RFC 9001 §4.6 0-RTT on the next connection. * * Plain `class` (not `data class`) intentionally: * - The `data class`-generated `equals` / `hashCode` use reference