Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Linking error potential fix #131

Merged
merged 5 commits into from
Jan 5, 2024

Conversation

neotheprogramist
Copy link
Contributor

@neotheprogramist neotheprogramist commented Dec 18, 2023

Description

This pull request addresses a critical linking error encountered in the Hyperledger Besu native library. The issue came to light following a modification in the method invocation within the PedersenHasher class, where LibIpaMultipoint.commit was changed to LibIpaMultipoint.commit_root. As a result of this change, a java.lang.UnsatisfiedLinkError is triggered when calling the commit_root method, with the error message: 'byte[] org.hyperledger.besu.nativelib.ipamultipoint.LibIpaMultipoint.commit_root(byte[])'.

Proposed Fix

The fix proposed in this pull request involves renaming the commit_root method from snake_case to camelCase. This renaming aims to:

  • Align with Java's standard naming conventions.
  • Potentially resolve the linking issues that are currently being faced.

Context

While other methods in the LibIpaMultipoint class, such as commit and pedersenHash, continue to operate as expected, it is believed that the naming convention employed for commit_root may be contributing to the linking error.

@matkt
Copy link
Contributor

matkt commented Dec 18, 2023

seems to work . could we add a small description in the PR ?

@thomas-quadratic
Copy link
Contributor

Shouldn't we have a test in ipa-multipoint/src/test/java/org/hyperledger/besu/nativelib/ipa_multipoint/ for this method as well ?

@thomas-quadratic
Copy link
Contributor

Good with me. Thanks!

Signed-off-by: Neo <neotheprogramist@proton.me>
Signed-off-by: Neo <neotheprogramist@proton.me>
Signed-off-by: Neo <neotheprogramist@proton.me>
Signed-off-by: Neo <neotheprogramist@proton.me>
Signed-off-by: Neo <neotheprogramist@proton.me>
Copy link
Contributor

@matkt matkt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lgtm

@thomas-quadratic
Copy link
Contributor

Good for me as well, thanks @neotheprogramist

@matkt matkt merged commit 2402ecb into hyperledger:main Jan 5, 2024
11 checks passed
kevaundray pushed a commit to kevaundray/besu-native that referenced this pull request Jan 24, 2024
Signed-off-by: Neo <neotheprogramist@proton.me>
Signed-off-by: Kevaundray Wedderburn <kevtheappdev@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants