Skip to content

Commit 082d03e

Browse files
committed
add new entrypoint ChannelManager::claim_funds_without_secret
1 parent 7352003 commit 082d03e

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

bindings/src/channelmanager.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -292,6 +292,12 @@ ffi! {
292292
FFIResult::ok()
293293
}
294294

295+
fn claim_funds_without_secret(payment_preimage: Ref<Bytes32>, expected_amount: u64, handle: FFIArcChannelManagerHandle, result: Out<Bool>) -> FFIResult {
296+
let r = claim_funds_inner(payment_preimage, None, expected_amount, handle);
297+
unsafe_block!("We know out parameter is writable" => result.init(r.into()));
298+
FFIResult::ok()
299+
}
300+
295301
fn update_fee(channel_id: Ref<[u8; 32]>, feerate_per_kw: u32, handle: FFIArcChannelManagerHandle) -> FFIResult {
296302
let chan_man: &FFIArcChannelManager = unsafe_block!("We know handle points to valid channel_manager" => handle.as_ref());
297303
let channel_id: &[u8;32] = unsafe_block!("" => channel_id.as_ref());

0 commit comments

Comments
 (0)