File tree Expand file tree Collapse file tree 3 files changed +9
-3
lines changed
aws-crt-kotlin/native/src/aws/sdk/kotlin/crt/util/hashing Expand file tree Collapse file tree 3 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -28,7 +28,9 @@ internal class Crc(val checksumFn: AwsChecksumsCrcFunction) : HashFunction {
2828 private var crc = 0U
2929
3030 override fun update (input : ByteArray , offset : Int , length : Int ) {
31- if (input.isEmpty() || length == 0 ) { return }
31+ if (input.isEmpty() || length == 0 ) {
32+ return
33+ }
3234
3335 val offsetInput = input.usePinned {
3436 it.addressOf(offset)
Original file line number Diff line number Diff line change @@ -31,7 +31,9 @@ public class Md5 : HashFunction {
3131 private var md5 = checkNotNull(aws_md5_new(Allocator .Default )) { " aws_md5_new" }
3232
3333 override fun update (input : ByteArray , offset : Int , length : Int ) {
34- if (input.isEmpty() || length == 0 ) { return }
34+ if (input.isEmpty() || length == 0 ) {
35+ return
36+ }
3537
3638 val inputCursor = input.usePinned {
3739 aws_byte_cursor_from_array(it.addressOf(offset), length.convert())
Original file line number Diff line number Diff line change @@ -55,7 +55,9 @@ internal class Sha(val initializeFn: InitializeHashFn) : HashFunction {
5555
5656 // aws_hash_update
5757 override fun update (input : ByteArray , offset : Int , length : Int ) {
58- if (input.isEmpty() || length == 0 ) { return }
58+ if (input.isEmpty() || length == 0 ) {
59+ return
60+ }
5961
6062 val inputCursor = input.usePinned {
6163 aws_byte_cursor_from_array(it.addressOf(offset), length.convert())
You can’t perform that action at this time.
0 commit comments