Server : Apache
System : Linux iZ6xhqomji47p1Z 5.10.134-15.al8.x86_64 #1 SMP Thu Jul 20 00:44:04 CST 2023 x86_64
User : www ( 1000)
PHP Version : 8.1.30
Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv
Directory :  /lib64/python3.6/__pycache__/
Upload File :
Current Directory [ Writeable ] Root Directory [ Writeable ]


Current File : //lib64/python3.6/__pycache__/pty.cpython-36.opt-2.pyc
3


 \��@s�ddlmZddlZddlZdddgZdZdZdZdZdd�Zd	d
�Z	dd�Z
d
d�Zdd�Zdd�Z
dd�Zeefdd�Zeefdd�ZdS)�)�selectN�openpty�fork�spawn��cCs<ytj�Sttfk
r YnXt�\}}t|�}||fS)N)�osr�AttributeError�OSError�_open_terminal�
slave_open)�	master_fd�
slave_name�slave_fd�r�/usr/lib64/python3.6/pty.pyrs
cCsLytj�\}}Wnttfk
r(YnXtj|�}tj|�||fSt�S)N)rrr	r
�ttyname�closer)r
rrrrr�master_open!s

rc
Cslx^dD]V}xPdD]H}d||}ytj|tj�}Wntk
rHwYnX|d||fSWqWtd��dS)NZpqrstuvwxyzPQRSTZ0123456789abcdefz/dev/ptyz/dev/ttyzout of pty devices)r�open�O_RDWRr
)�x�yZpty_name�fdrrrr1s

rcCsntj|tj�}yddlm}m}Wntk
r6|SXy|||d�|||d�Wntk
rhYnX|S)Nr)�ioctl�I_PUSHZptemZldterm)rrrZfcntlrr�ImportErrorr
)Ztty_name�resultrrrrrr=srcCs�ytj�\}}Wnttfk
r(Yn4X|tkrTytj�Wntk
rRYnX||fSt�\}}tj�}|tkr�tj�tj|�tj	|t
�tj	|t�tj	|t�|tkr�tj|�tj
tjt�tj�}tj|�n
tj|�||fS)N)r�forkptyr	r
�CHILD�setsidrrr�dup2�STDIN_FILENO�
STDOUT_FILENO�
STDERR_FILENOrrr)�pidrr
rZtmp_fdrrrrOs0



cCs&x |r tj||�}||d�}qWdS)N)r�write)r�data�nrrr�_writenwsr)cCstj|d�S)Ni)r�read)rrrr�_read}sr+cCsz|tg}xlt|gg�\}}}||krH||�}|s<|j|�ntjt|�t|kr
|t�}|sh|jt�q
t||�q
WdS)N)r"r�removerr&r#r))r
�master_read�
stdin_readZfdsZrfdsZwfdsZxfdsr'rrr�_copy�sr/cCs�t|�td�kr|f}t�\}}|tkr<tj|df|��ytjt�}tjt�d}Wntj	k
rrd}YnXyt
|||�Wn(tk
r�|r�tjttj
|�YnXtj|�tj|d�dS)N�rr)�typerrr�execlp�ttyZ	tcgetattrr"Zsetraw�errorr/r
Z	tcsetattrZ	TCSAFLUSHr�waitpid)�argvr-r.r%r
�modeZrestorerrrr�s$




)rrr3�__all__r"r#r$rrrrrrr)r+r/rrrrr�<module>	s 
(