From 0ea77d783a4a84ed66ada28f56e533ec4b9b4ef1 Mon Sep 17 00:00:00 2001 From: George Kadianakis Date: Thu, 26 Sep 2024 19:00:33 +0300 Subject: [PATCH] Trivial fixes in the bindings --- bindings/csharp/Ckzg.Bindings/Ckzg.cs | 2 +- bindings/java/ckzg_jni.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bindings/csharp/Ckzg.Bindings/Ckzg.cs b/bindings/csharp/Ckzg.Bindings/Ckzg.cs index 08b3f6a5..8f109a0c 100644 --- a/bindings/csharp/Ckzg.Bindings/Ckzg.cs +++ b/bindings/csharp/Ckzg.Bindings/Ckzg.cs @@ -188,7 +188,7 @@ public static unsafe bool VerifyBlobKzgProofBatch(ReadOnlySpan blobs, Read { ThrowOnUninitializedTrustedSetup(ckzgSetup); ThrowOnInvalidLength(blobs, nameof(blobs), BytesPerBlob * count); - ThrowOnInvalidLength(commitments, nameof(proofs), BytesPerCommitment * count); + ThrowOnInvalidLength(commitments, nameof(commitments), BytesPerCommitment * count); ThrowOnInvalidLength(proofs, nameof(proofs), BytesPerProof * count); fixed (byte* blobsPtr = blobs, commitmentsPtr = commitments, proofsPtr = proofs) diff --git a/bindings/java/ckzg_jni.c b/bindings/java/ckzg_jni.c index 2b697302..5f1978bf 100644 --- a/bindings/java/ckzg_jni.c +++ b/bindings/java/ckzg_jni.c @@ -637,7 +637,7 @@ Java_ethereum_ckzg4844_CKZG4844JNI_verifyCellKzgProofBatch( (size_t)(*env)->GetArrayLength(env, commitments_bytes); if (commitments_size % BYTES_PER_COMMITMENT != 0) { throw_invalid_size_exception(env, "Invalid commitments size.", - commitments_size % BYTES_PER_COMMITMENT, + commitments_size, BYTES_PER_COMMITMENT); return 0; }