Fix (modified) audiod.
This commit is contained in:
@@ -212,7 +212,7 @@ asmfunction!(__relibc_internal_sigentry: ["
|
||||
lock btr [rcx + {pctl_off_pending}], eax
|
||||
jnc 1b
|
||||
2:
|
||||
mov eax, edx
|
||||
mov edx, eax
|
||||
shr edx, 5
|
||||
lock btr fs:[{tcb_sc_off} + {sc_word} + edx * 4], eax
|
||||
add eax, 64 // indicate signal was targeted at thread
|
||||
|
||||
@@ -42,7 +42,8 @@ pub struct SigStack {
|
||||
unsafe fn inner(stack: &mut SigStack) {
|
||||
let os = &Tcb::current().unwrap().os_specific;
|
||||
|
||||
let sig_idx = stack.sig_num;
|
||||
let _targeted_thread_not_process = stack.sig_num >= 64;
|
||||
stack.sig_num %= 64;
|
||||
|
||||
// asm counts from 0
|
||||
stack.sig_num += 1;
|
||||
|
||||
@@ -802,9 +802,8 @@ impl Pal for Sys {
|
||||
os_tid: crate::pthread::OsTid,
|
||||
signal: usize,
|
||||
) -> Result<(), crate::pthread::Errno> {
|
||||
todo!();
|
||||
/*syscall::kill(os_tid.context_id, signal)
|
||||
.map_err(|error| crate::pthread::Errno(error.errno))?;*/
|
||||
let killfd = FdGuard::new(syscall::dup(os_tid.thread_fd, b"signal")?);
|
||||
syscall::write(*killfd, &(signal as u32).to_ne_bytes())?;
|
||||
Ok(())
|
||||
}
|
||||
fn current_os_tid() -> crate::pthread::OsTid {
|
||||
|
||||
Reference in New Issue
Block a user