Modify a thread context, setting the RAX register to signal an error. Note: Should only be applied to threads that will return from a syscall.
(&self, error_code: usize)
| 174 | /// Note: Should only be applied to threads that |
| 175 | /// will return from a syscall. |
| 176 | pub fn return_error(&self, error_code: usize) { |
| 177 | // Ensure that the error is in range, no message |
| 178 | self.context_mut().rax = error_code & |
| 179 | syscalls::SYSCALL_ERROR_MASK; |
| 180 | } |
| 181 | |
| 182 | /// Modify a thread context, setting registers |
| 183 | /// |
no test coverage detected