AlkantarClanX12

Your IP : 13.59.134.65


Current Path : /lib64/python3.8/multiprocessing/__pycache__/
Upload File :
Current File : //lib64/python3.8/multiprocessing/__pycache__/popen_fork.cpython-38.pyc

U

e5d
�@s6ddlZddlZddlmZdgZGdd�de�ZdS)�N�)�util�Popenc@s`eZdZdZdd�Zdd�Zejfdd�Zdd	d
�Z	dd�Z
d
d�Zdd�Zdd�Z
dd�ZdS)r�forkcCs"t��d|_d|_|�|�dS�N)rZ_flush_std_streams�
returncode�	finalizer�_launch)�self�process_obj�r�2/usr/lib64/python3.8/multiprocessing/popen_fork.py�__init__szPopen.__init__cCs|Srr)r
�fdrrr
�duplicate_for_childszPopen.duplicate_for_childc
Cs�|jdkr�zt�|j|�\}}Wn(tk
rH}z
WY�dSd}~XYnX||jkr�t�|�rnt�|�|_n$t�|�s�td�	|���t�
|�|_|jS)NzStatus is {:n})r�os�waitpid�pid�OSError�WIFSIGNALED�WTERMSIG�	WIFEXITED�AssertionError�format�WEXITSTATUS)r
�flagr�sts�errr
�polls


z
Popen.pollNcCsN|jdkrH|dk	r0ddlm}||jg|�s0dS|�|dkrBtjnd�S|jS)Nr)�waitg)rZmultiprocessing.connectionr�sentinelrr�WNOHANG)r
�timeoutrrrr
r(s
z
Popen.waitcCsZ|jdkrVzt�|j|�Wn8tk
r0Yn&tk
rT|jdd�dkrP�YnXdS)Ng�������?)r")rr�killr�ProcessLookupErrorrr)r
Zsigrrr
�_send_signal2s
zPopen._send_signalcCs|�tj�dSr)r%�signal�SIGTERM�r
rrr
�	terminate<szPopen.terminatecCs|�tj�dSr)r%r&�SIGKILLr(rrr
r#?sz
Popen.killc	Cs�d}t��\}}t��\}}t��|_|jdkrdz$t�|�t�|�|j|d�}W5t�|�Xn0t�|�t�|�t�|tj	||f�|_
||_dS)Nrr)Zparent_sentinel)r�piperr�_exit�close�
_bootstraprZFinalizeZ	close_fdsrr )r
r�codeZparent_rZchild_wZchild_rZparent_wrrr
r	Bs 






�z
Popen._launchcCs|jdk	r|��dSr)rr(rrr
r-Us
zPopen.close)N)�__name__�
__module__�__qualname__�methodrrrr!rrr%r)r#r	r-rrrr
rs


)rr&�r�__all__�objectrrrrr
�<module>s