diff --git a/src/lib.rs b/src/lib.rs index e8987b7..4a6c23c 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,4 +1,4 @@ -#![feature(path_absolute_method)] +#![feature(path_absolute_method, never_type)] use std::path::{Path, PathBuf}; use std::sync::OnceLock; diff --git a/src/tftp/server.rs b/src/tftp/server.rs index 35ec72c..2cf1f24 100644 --- a/src/tftp/server.rs +++ b/src/tftp/server.rs @@ -145,7 +145,7 @@ where Ok(()) } -pub async fn serve(callback: F) -> Result<(), Error> +pub async fn serve(callback: F) -> Result where F: Fn(&str) -> Fut + Clone + Send + 'static, Fut: Future>> + Send + 'static,