diff --git a/examples/mioudp/src/main.rs b/examples/mioudp/src/main.rs index c46cc04e0..194cf7b0e 100644 --- a/examples/mioudp/src/main.rs +++ b/examples/mioudp/src/main.rs @@ -1,10 +1,9 @@ +//! Adapted from . + use std::io; -use std::str::from_utf8; #[cfg(target_os = "hermit")] use hermit as _; -// This example is derived from -// https://github.com/tokio-rs/mio/blob/master/examples/tcp_server.rs use log::warn; use mio::{Events, Interest, Poll, Token}; @@ -63,11 +62,6 @@ fn main() -> io::Result<()> { Ok((packet_size, source_address)) => { // Echo the data. socket.send_to(&buf[..packet_size], source_address)?; - if let Ok(str_buf) = from_utf8(&buf[..packet_size]) { - if str_buf.trim_end() == "exit" { - return Ok(()); - } - } } Err(e) if e.kind() == io::ErrorKind::WouldBlock => { // If we get a `WouldBlock` error we know our socket diff --git a/kernel b/kernel index 0c8198c66..542162fd9 160000 --- a/kernel +++ b/kernel @@ -1 +1 @@ -Subproject commit 0c8198c6662497c80220fb76048fa27b3119c98d +Subproject commit 542162fd9ef109a2c3d9ed675de9a16f3e8b0410