From 4710b416be5ca8d473acf891a1af99dcce801585 Mon Sep 17 00:00:00 2001 From: bunnie Date: Fri, 28 Feb 2025 16:36:24 +0800 Subject: [PATCH] cleanup trait implementation to match modifications remove mutability from get_pixel --- services/graphics-server/src/backend/betrusted.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/services/graphics-server/src/backend/betrusted.rs b/services/graphics-server/src/backend/betrusted.rs index 108ce75f1..3b873ffcc 100644 --- a/services/graphics-server/src/backend/betrusted.rs +++ b/services/graphics-server/src/backend/betrusted.rs @@ -314,8 +314,8 @@ impl FrameBuffer for XousDisplay { /// /// Note: this has not be carefully tested as this API is not used by the legacy code base. /// Anyone using this API for the first time may benefit in checking that it is correct. - fn get_pixel(&mut self, p: Point) -> Option { - let fb: &mut [u32] = unsafe { self.fb.as_slice_mut() }; + fn get_pixel(&self, p: Point) -> Option { + let fb: &[u32] = unsafe { self.fb.as_slice() }; let clip_y: usize; if p.y >= LCD_LINES { return None;