Update to new struct version of FileWriteMode

This commit is contained in:
pjht 2024-11-17 21:51:46 -06:00
parent 88815ccaea
commit 3190f78d0b
Signed by: pjht
GPG Key ID: 7B5F6AFBEC7EE78E

View File

@ -91,8 +91,7 @@ impl file_rpc::Server for Serv {
}
fn dup(&self, fd: u64) -> Result<u64, Errno> {
let file = self.open_files.get(fd as usize).ok_or(Errno::EBADF)?.clone();
self.open_files.insert(file).map(|x| x as u64).ok_or(Errno::ENOMEM)
Ok(fd)
}
fn seek(&self, fd: u64, pos: file_rpc::SeekFrom) -> Result<u64, Errno> {