diff --git a/vhost-device-template/src/vhu_foo.rs b/vhost-device-template/src/vhu_foo.rs index 04b2f79..8d87405 100644 --- a/vhost-device-template/src/vhu_foo.rs +++ b/vhost-device-template/src/vhu_foo.rs @@ -49,7 +49,7 @@ pub(crate) enum Error { impl convert::From for io::Error { fn from(e: Error) -> Self { - io::Error::new(io::ErrorKind::Other, e) + io::Error::other(e) } } @@ -210,7 +210,7 @@ impl VhostUserBackendMut for VhostUserFooBackend { } _ => { - warn!("unhandled device_event: {}", device_event); + warn!("unhandled device_event: {device_event}"); return Err(Error::HandleEventUnknown.into()); } }