From a21911cc30e77d4f0e96e96ec6eba1829ac6d625 Mon Sep 17 00:00:00 2001 From: pjht Date: Sat, 16 Nov 2024 11:54:26 -0600 Subject: [PATCH] Add mode to open operation --- src/main.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main.rs b/src/main.rs index 4194ca6..7b257ea 100644 --- a/src/main.rs +++ b/src/main.rs @@ -24,7 +24,7 @@ use std::{ borrow::Cow, collections::{HashMap, VecDeque}, fmt::{self, Write}, - os::mikros::{address_space::ACTIVE_SPACE, ipc, syscalls, Errno}, + os::mikros::{address_space::ACTIVE_SPACE, ipc, syscalls, Errno, FileOpenMode}, }; use fontdue::{ @@ -336,7 +336,7 @@ impl fmt::Write for FramebufferWriter { struct DevServ; impl dev_driver_rpc::Server for DevServ { - fn open(&self, _path: &std::path::Path) -> Result { + fn open(&self, _path: &std::path::Path, _mode: FileOpenMode) -> Result { Ok(0) } } @@ -361,7 +361,7 @@ impl file_rpc::Server for FileServ { let string = String::from_utf8_lossy(data); let mut fbwriter = self.fbwriter.lock(); let mut fbuffer = self.fbuffer.lock(); - let _ = fbwriter.write_str(&*string); // never errors + let _ = fbwriter.write_str(&string); // never errors fbwriter.update_screen(&mut fbuffer); Ok(()) }