Skip to content

Commit

Permalink
Fix UART queue (#304)
Browse files Browse the repository at this point in the history
  • Loading branch information
torkleyy authored Sep 15, 2023
1 parent d7ca04f commit 0d0d41e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/uart.rs
Original file line number Diff line number Diff line change
Expand Up @@ -668,8 +668,8 @@ impl<'d> UartDriver<'d> {
// SAFTEY: okay because Queue borrows self
// SAFETY: we can safely use UartEvent instead of uart_event_t because of repr(transparent)
let queue = match q_handle_raw.is_null() {
true => Some(unsafe { Queue::new_borrowed(q_handle_raw) }),
false => None,
false => Some(unsafe { Queue::new_borrowed(q_handle_raw) }),
true => None,
};

Ok(Self {
Expand Down

0 comments on commit 0d0d41e

Please sign in to comment.