forked from Rativel/BurritOS
Fix exceptions with semaphore
This commit is contained in:
@@ -3,7 +3,6 @@
|
||||
//! Module containing structs and methods pertaining to the state of the operating system
|
||||
|
||||
use super::{thread_manager::ThreadManager};
|
||||
use crate::utility::objaddr::ObjAddr;
|
||||
|
||||
/// # System
|
||||
///
|
||||
@@ -16,8 +15,7 @@ use crate::utility::objaddr::ObjAddr;
|
||||
/// - The thread to be destroyed next
|
||||
/// - The scheduler which acts upon these threads
|
||||
pub struct System {
|
||||
thread_manager: ThreadManager,
|
||||
obj_addrs: ObjAddr
|
||||
thread_manager: ThreadManager
|
||||
}
|
||||
|
||||
impl System {
|
||||
@@ -28,14 +26,12 @@ impl System {
|
||||
&mut self.thread_manager
|
||||
}
|
||||
|
||||
pub fn get_obj_addrs(&mut self) -> &mut ObjAddr { &mut self.obj_addrs }
|
||||
|
||||
}
|
||||
|
||||
impl Default for System {
|
||||
/// System constructor
|
||||
fn default() -> Self {
|
||||
Self { thread_manager: ThreadManager::new(), obj_addrs: ObjAddr::init() }
|
||||
Self { thread_manager: ThreadManager::new() }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user