1cfg_if::cfg_if! {
6 if #[cfg(any(target_os = "android", target_os = "linux"))] {
7 pub mod linux;
8 use linux as platform;
9 } else if #[cfg(windows)] {
10 pub mod windows;
11 use windows as platform;
12 }
13}
14
15pub struct PendingBuffer {
16 pub buffer: Box<[u8; 65562]>,
20 pub length: u32,
21}
22
23impl PendingBuffer {
24 pub fn new() -> Self {
25 PendingBuffer {
26 buffer: Box::new([0u8; 65562]),
27 length: 0,
28 }
29 }
30}
31
32impl Default for PendingBuffer {
33 fn default() -> Self {
34 Self::new()
35 }
36}
37
38pub use platform::process_mrg_rx;
39pub use platform::process_rx;
40pub use platform::process_tx;
41pub use platform::validate_and_configure_tap;
42pub use platform::virtio_features_to_tap_offload;