pub fn sys_shmdt(&self, id: usize, addr: VirtAddr, shmflg: usize) -> SysResult {
        info!(
            "shmdt: id = {}, addr = {:#x}, flag = {:#x}",
            id, addr, shmflg
        );
        let proc = self.linux_process();
        let opt_id = proc.shm_get_id(addr);
        if let Some(id) = opt_id {
            let shm_identifier = proc.shm_get(id).ok_or(LxError::EINVAL)?;
            proc.shm_pop(id);
            shm_identifier
                .guard
                .lock()
                .detach(self.zircon_process().id() as u32);
        }
        Ok(0)
    }
/// detaches the shared memory segment located at the address specified by shmaddr
/// from the address space of the calling process.
detaches the shared memory segment located at the address specified by shmaddr
from the address space of the calling process.
detaches the shared memory segment located at the address specified by shmaddr from the address space of the calling process .
pub fn sys_shmdt(&self, id: usize, addr: VirtAddr, shmflg: usize) -> SysResult {
        info!(
            "shmdt: id = {}, addr = {:#x}, flag = {:#x}",
            id, addr, shmflg
        );
        let proc = self.linux_process();
        let opt_id = proc.shm_get_id(addr);
        if let Some(id) = opt_id {
            let shm_identifier = proc.shm_get(id).ok_or(LxError::EINVAL)?;
            proc.shm_pop(id);
            shm_identifier
                .guard
                .lock()
                .detach(self.zircon_process().id() as u32);
        }
        Ok(0)
    }
pub fn sys_shmdt ( & self , id : usize , addr : VirtAddr , shmflg : usize ) -> SysResult { info ! ( " " id addr shmflg ) ; let proc = self . linux_process ( ) ; let opt_id = proc . shm_get_id ( addr ) ; if let Some ( id ) = opt_id { let shm_identifier = proc . shm_get ( id ) . ok_or ( LxError :: EINVAL ) ? ; proc . shm_pop ( id ) ; shm_identifier . guard . lock ( ) . detach ( self . zircon_process ( ) . id ( ) as u32 ) ; } Ok ( 0 ) }
detaches the shared memory segment located at the address specified by shmaddr
from the address space of the calling process.
detaches the shared memory segment located at the address specified by shmaddr from the address space of the calling process .
&self
id
usize
addr
VirtAddr
shmflg
usize
&self
id
usize
addr
VirtAddr
shmflg
usize