restore 10 zaddr by default, and allow variable zaddr size

This commit is contained in:
DenioD
2020-06-18 13:46:04 +02:00
parent 0320bc9f13
commit 5f67dd4a32
6 changed files with 34 additions and 16 deletions

View File

@@ -102,7 +102,7 @@ pub extern fn litelib_initialize_new(dangerous: bool, server: *const c_char) ->
/// Restore a wallet from the seed phrase
#[no_mangle]
pub extern fn litelib_initialize_new_from_phrase(dangerous: bool, server: *const c_char,
seed: *const c_char, birthday: u64) -> *mut c_char {
seed: *const c_char, birthday: u64, number: u64) -> *mut c_char {
let server_str = unsafe {
assert!(!server.is_null());
@@ -124,7 +124,7 @@ pub extern fn litelib_initialize_new_from_phrase(dangerous: bool, server: *const
}
};
let lightclient = match LightClient::new_from_phrase(seed_str, &config, birthday) {
let lightclient = match LightClient::new_from_phrase(seed_str, &config, birthday, number, false) {
Ok(l) => l,
Err(e) => {
let e_str = CString::new(format!("Error: {}", e)).unwrap();