Skip to content

Commit 2794930

Browse files
committed
ktlint
1 parent b882663 commit 2794930

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

runtime/runtime-core/native/src/aws/smithy/kotlin/runtime/compression/GzipCompressor.kt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,14 @@
55
package aws.smithy.kotlin.runtime.compression
66

77
import aws.sdk.kotlin.crt.Closeable
8+
import aws.smithy.kotlin.runtime.io.SdkBuffer
89
import aws.smithy.kotlin.runtime.io.SdkByteChannel
910
import aws.smithy.kotlin.runtime.io.readFully
11+
import aws.smithy.kotlin.runtime.io.readToByteArray
12+
import aws.smithy.kotlin.runtime.io.use
1013
import aws.smithy.kotlin.runtime.io.write
1114
import kotlinx.cinterop.*
1215
import platform.zlib.*
13-
import aws.smithy.kotlin.runtime.io.SdkBuffer
14-
import aws.smithy.kotlin.runtime.io.readToByteArray
15-
import aws.smithy.kotlin.runtime.io.use
1616

1717
private const val DEFAULT_WINDOW_BITS = 15 // Default window bits
1818
private const val WINDOW_BITS_GZIP_OFFSET = 16 // Gzip offset for window bits
@@ -53,7 +53,7 @@ internal class GzipCompressor : Closeable {
5353
* Update the compressor with [input] bytes
5454
*/
5555
suspend fun update(input: ByteArray) = memScoped {
56-
check (!isClosed) { "Compressor is closed" }
56+
check(!isClosed) { "Compressor is closed" }
5757

5858
val inputPin = input.pin()
5959

@@ -83,7 +83,7 @@ internal class GzipCompressor : Closeable {
8383
* Consume [count] gzip-compressed bytes.
8484
*/
8585
suspend fun consume(count: Int): ByteArray {
86-
check (!isClosed) { "Compressor is closed" }
86+
check(!isClosed) { "Compressor is closed" }
8787
require(count in 0..availableForRead) {
8888
"Count must be between 0 and $availableForRead, got $count"
8989
}
@@ -98,7 +98,7 @@ internal class GzipCompressor : Closeable {
9898
* Flush the compressor and return the terminal sequence of bytes that represent the end of the gzip compression.
9999
*/
100100
suspend fun flush(): ByteArray {
101-
check (!isClosed) { "Compressor is closed" }
101+
check(!isClosed) { "Compressor is closed" }
102102

103103
memScoped {
104104
val compressionBuffer = ByteArray(BUFFER_SIZE)

runtime/runtime-core/native/src/aws/smithy/kotlin/runtime/io/GzipSdkSourceNative.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ public actual class GzipSdkSource actual constructor(public val source: SdkSourc
2929
if (rc > 0) {
3030
val input = temp.readByteArray(rc)
3131
runBlocking { compressor.update(input) }
32-
3332
}
3433
}
3534

0 commit comments

Comments
 (0)