Skip to content

Commit

Permalink
Fix copy/paste error
Browse files Browse the repository at this point in the history
  • Loading branch information
luben committed Sep 26, 2023
1 parent 2cbe15f commit e0c66f1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/native/jni_zstd.c
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,7 @@ JNIEXPORT jlong JNICALL Java_com_github_luben_zstd_Zstd_decompressedDirectByteBu
char *src_buf_ptr = (char*)(*env)->GetDirectBufferAddress(env, src_buf);
if (src_buf_ptr == NULL) goto E1;
size = JNI_ZSTD_decompressedSize(src_buf_ptr + src_offset, (size_t) src_size, magicless);
if (size <= 0) return 0;
E1: return size;
}

Expand All @@ -185,7 +186,6 @@ JNIEXPORT jlong JNICALL Java_com_github_luben_zstd_Zstd_getDirectByteBufferFrame
char *src_buf_ptr = (char*)(*env)->GetDirectBufferAddress(env, src_buf);
if (src_buf_ptr == NULL) goto E1;
size = JNI_ZSTD_decompressedSize(src_buf_ptr + src_offset, (size_t) src_size, magicless);
if (size <= 0) return 0;
E1: return size;
}

Expand Down

0 comments on commit e0c66f1

Please sign in to comment.