-
Notifications
You must be signed in to change notification settings - Fork 11
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
Incorrect documentation and usage of RustBackend.importAccountUfvk JNI function #1651
Comments
Both of those conversions are fallible, so I don't think the nullity of the arguments can cause a crash? |
I think that nullability and, thus, null values for these two arguments should be fine. This is how @str4d prepared the JNI layer for us, so the Kotlin side just follows it - link. But we rather double-check it and come back. @Milan-Cerovsky will call the viewing-only purpose version of the API. |
In let seed_fingerprint =
<[u8; 32]>::try_from(&env.convert_byte_array(seed_fingerprint_bytes)?[..])
.ok()
.map(SeedFingerprint::from_bytes);
let hd_account_index = zip32::AccountId::try_from(hd_account_index_raw).ok();
let derivation = seed_fingerprint
.zip(hd_account_index)
.map(|(seed_fp, idx)| Zip32Derivation::new(seed_fp, idx)); And here's the implementation of Unless I'm misreading, the The fix is to apply this suggestion. |
Fixed in #1656 |
Originally posted by @daira at #1640 (comment) :
and at #1640 (comment) :
The text was updated successfully, but these errors were encountered: