X-Git-Url: http://git.bitcoin.ninja/index.cgi?p=ldk-c-bindings;a=blobdiff_plain;f=lightning-c-bindings%2Fsrc%2Flightning%2Frouting%2Frouter.rs;fp=lightning-c-bindings%2Fsrc%2Flightning%2Frouting%2Frouter.rs;h=8c129955aefcb81df3438189bfb38fc03a8b95db;hp=48da60ed13ee2576b6ab0612b568dd2d5c792ef1;hb=8e312af8e3dc1de09d5ed95372c1cfab8d83a6d0;hpb=9bcc4df3b321b69ebf0d0813bc16dac0771fc64f diff --git a/lightning-c-bindings/src/lightning/routing/router.rs b/lightning-c-bindings/src/lightning/routing/router.rs index 48da60e..8c12995 100644 --- a/lightning-c-bindings/src/lightning/routing/router.rs +++ b/lightning-c-bindings/src/lightning/routing/router.rs @@ -716,6 +716,17 @@ pub extern "C" fn PaymentParameters_set_max_channel_saturation_power_of_half(thi /// A list of SCIDs which this payment was previously attempted over and which caused the /// payment to fail. Future attempts for the same payment shouldn't be relayed through any of /// these SCIDs. +/// +/// Returns a copy of the field. +#[no_mangle] +pub extern "C" fn PaymentParameters_get_previously_failed_channels(this_ptr: &PaymentParameters) -> crate::c_types::derived::CVec_u64Z { + let mut inner_val = this_ptr.get_native_mut_ref().previously_failed_channels.clone(); + let mut local_inner_val = Vec::new(); for mut item in inner_val.drain(..) { local_inner_val.push( { item }); }; + local_inner_val.into() +} +/// A list of SCIDs which this payment was previously attempted over and which caused the +/// payment to fail. Future attempts for the same payment shouldn't be relayed through any of +/// these SCIDs. #[no_mangle] pub extern "C" fn PaymentParameters_set_previously_failed_channels(this_ptr: &mut PaymentParameters, mut val: crate::c_types::derived::CVec_u64Z) { let mut local_val = Vec::new(); for mut item in val.into_rust().drain(..) { local_val.push( { item }); };