summaryrefslogtreecommitdiff
path: root/src/vhost_user/slave_fs_cache.rs
diff options
context:
space:
mode:
authorKeiichi Watanabe <keiichiw@chromium.org>2021-02-24 21:21:32 +0900
committerJiang Liu <gerry@linux.alibaba.com>2021-03-03 19:33:56 +0800
commit62fd4ec5a47d1b9cd1ea2c8702228ea216b92686 (patch)
treeef9bb7f8b3371f8792c76058d5856cac8bc1cd31 /src/vhost_user/slave_fs_cache.rs
parent576694bcfb09e7c78d812ed07dbc5377d283852a (diff)
downloadvmm_vhost-62fd4ec5a47d1b9cd1ea2c8702228ea216b92686.tar.gz
Fix clippy erros and warnings
Make `cargo clippy --all-features --all-targets` pass. Signed-off-by: Keiichi Watanabe <keiichiw@chromium.org>
Diffstat (limited to 'src/vhost_user/slave_fs_cache.rs')
-rw-r--r--src/vhost_user/slave_fs_cache.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/vhost_user/slave_fs_cache.rs b/src/vhost_user/slave_fs_cache.rs
index 1e2ef61..a9c4ed2 100644
--- a/src/vhost_user/slave_fs_cache.rs
+++ b/src/vhost_user/slave_fs_cache.rs
@@ -104,7 +104,7 @@ impl SlaveFsCacheReq {
) -> io::Result<u64> {
self.node()
.send_message(request, fs, fds)
- .or_else(|e| Err(io::Error::new(io::ErrorKind::Other, format!("{}", e))))
+ .map_err(|e| io::Error::new(io::ErrorKind::Other, format!("{}", e)))
}
/// Create a new instance from a `UnixStream` object.