2020-08-10 15:00:09 -04:00
|
|
|
// This file is Copyright its original authors, visible in version control
|
|
|
|
// history.
|
|
|
|
//
|
|
|
|
// This file is licensed under the Apache License, Version 2.0 <LICENSE-APACHE
|
|
|
|
// or http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
|
|
|
|
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your option.
|
|
|
|
// You may not use this file except in accordance with one or both of these
|
|
|
|
// licenses.
|
|
|
|
|
2018-08-29 15:56:48 -04:00
|
|
|
// This file is auto-generated by gen_target.sh based on msg_target_template.txt
|
|
|
|
// To modify it, modify msg_target_template.txt and run gen_target.sh instead.
|
|
|
|
|
2019-12-11 13:18:43 -05:00
|
|
|
use msg_targets::utils::VecWriter;
|
2020-02-20 20:11:40 -05:00
|
|
|
use utils::test_logger;
|
2018-08-29 15:56:48 -04:00
|
|
|
|
2018-07-23 00:59:16 +00:00
|
|
|
#[inline]
|
2020-02-20 20:11:40 -05:00
|
|
|
pub fn msg_init_test<Out: test_logger::Output>(data: &[u8], _out: Out) {
|
2022-07-01 20:55:03 +00:00
|
|
|
test_msg_simple!(lightning::ln::msgs::Init, data);
|
2018-07-23 00:59:16 +00:00
|
|
|
}
|
|
|
|
|
2019-12-11 13:18:43 -05:00
|
|
|
#[no_mangle]
|
|
|
|
pub extern "C" fn msg_init_run(data: *const u8, datalen: usize) {
|
2020-02-20 20:11:40 -05:00
|
|
|
let data = unsafe { std::slice::from_raw_parts(data, datalen) };
|
2022-07-01 20:55:03 +00:00
|
|
|
test_msg_simple!(lightning::ln::msgs::Init, data);
|
2018-07-23 00:59:16 +00:00
|
|
|
}
|