Skip to content

Commit dc08e0b

Browse files
authored
Merge pull request #974 from korken89/fix-alloc-required
`extern crate alloc` was added accidentally breaking downstream `no_std`
2 parents 30966f3 + ee1a9e5 commit dc08e0b

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/phy/fuzz_injector.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
1-
extern crate alloc;
2-
use alloc::vec::Vec;
3-
41
use crate::phy::{self, Device, DeviceCapabilities};
52
use crate::time::Instant;
3+
use alloc::vec::Vec;
64

75
// This could be fixed once associated consts are stable.
86
const MTU: usize = 1536;

src/phy/mod.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,7 @@ use crate::time::Instant;
9797
mod sys;
9898

9999
mod fault_injector;
100+
#[cfg(feature = "alloc")]
100101
mod fuzz_injector;
101102
#[cfg(feature = "alloc")]
102103
mod loopback;
@@ -117,6 +118,7 @@ mod tuntap_interface;
117118
pub use self::sys::wait;
118119

119120
pub use self::fault_injector::FaultInjector;
121+
#[cfg(feature = "alloc")]
120122
pub use self::fuzz_injector::{FuzzInjector, Fuzzer};
121123
#[cfg(feature = "alloc")]
122124
pub use self::loopback::Loopback;

0 commit comments

Comments
 (0)