Merge pull request #1552 from embassy-rs/log-fix
usb-logger: fix breakage in log 0.4.19
This commit is contained in:
commit
c5a0e8579a
@ -138,7 +138,7 @@ macro_rules! run {
|
|||||||
( $x:expr, $l:expr, $p:ident ) => {
|
( $x:expr, $l:expr, $p:ident ) => {
|
||||||
static LOGGER: ::embassy_usb_logger::UsbLogger<$x> = ::embassy_usb_logger::UsbLogger::new();
|
static LOGGER: ::embassy_usb_logger::UsbLogger<$x> = ::embassy_usb_logger::UsbLogger::new();
|
||||||
unsafe {
|
unsafe {
|
||||||
let _ = ::log::set_logger_racy(&LOGGER).map(|()| log::set_max_level($l));
|
let _ = ::log::set_logger_racy(&LOGGER).map(|()| log::set_max_level_racy($l));
|
||||||
}
|
}
|
||||||
let _ = LOGGER.run(&mut ::embassy_usb_logger::LoggerState::new(), $p).await;
|
let _ = LOGGER.run(&mut ::embassy_usb_logger::LoggerState::new(), $p).await;
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user