Adding fuzzers for gossip_queries messages
[rust-lightning] / fuzz / src / msg_targets / msg_gossip_timestamp_filter.rs
diff --git a/fuzz/src/msg_targets/msg_gossip_timestamp_filter.rs b/fuzz/src/msg_targets/msg_gossip_timestamp_filter.rs
new file mode 100644 (file)
index 0000000..73999cd
--- /dev/null
@@ -0,0 +1,27 @@
+// 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.
+
+// 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.
+
+use lightning::ln::msgs;
+
+use msg_targets::utils::VecWriter;
+use utils::test_logger;
+
+#[inline]
+pub fn msg_gossip_timestamp_filter_test<Out: test_logger::Output>(data: &[u8], _out: Out) {
+       test_msg!(msgs::GossipTimestampFilter, data);
+}
+
+#[no_mangle]
+pub extern "C" fn msg_gossip_timestamp_filter_run(data: *const u8, datalen: usize) {
+       let data = unsafe { std::slice::from_raw_parts(data, datalen) };
+       test_msg!(msgs::GossipTimestampFilter, data);
+}