[TS] Correctly pass u64s from TS to C, using BigInts
[ldk-java] / genbindings.py
index c5bc0b1f28b07d315227d351a57f77c1dcb732f7..34c3fe1904ec2610eb3cd43c4762b20d4e39604d 100755 (executable)
@@ -150,7 +150,7 @@ def java_c_types(fn_arg, ret_arr_len):
         rust_obj = "LDKSignature"
         arr_access = "compact_form"
     elif fn_arg.startswith("LDKRecoverableSignature"):
-        fn_arg = "uint8_t (*" + fn_arg[25:] + ")[68]"
+        fn_arg = "uint8_t (*" + fn_arg[24:] + ")[68]"
         assert var_is_arr_regex.match(fn_arg[8:])
         rust_obj = "LDKRecoverableSignature"
         arr_access = "serialized_form"
@@ -279,6 +279,7 @@ def java_c_types(fn_arg, ret_arr_len):
             c_ty = "int64_t"
             fn_arg = fn_arg[8:].strip()
         else:
+            java_ty = consts.ptr_native_ty
             c_ty = "int64_t"
             rust_obj = "uintptr_t"
             fn_arg = fn_arg[9:].strip()