Hacked By AnonymousFox
3
� f�� �
@ s d Z ddlZddlZddlZddlZddlZddlZddlZddlZddl Z ddl
mZ ddl
mZ ddl
m
Z
ddl
mZ ddl
mZ dd l
mZ dd
l
mZ ddl
mZ ddl
mZ dd
l
mZ ddlmZ ddlmZ dddddgZejdkr�ed��dd� Zy
ejZW n ek
�r, dd� ZY nX G dd� dej�Z e!ed��rVdd� Z"nddl#Z#d d� Z"G d!d"� d"ej$�Z%G d#d$� d$ej&ej'�Z(e!ed%��r�ej)Z*nddl#Z#d&d'� Z*G d(d)� d)ej+�Z,G d*d� d�Z-G d+d,� d,e-�Z.G d-d� de.�Z/G d.d� de.�Z0G d/d0� d0ej1�Z2e Z3e2Z4dS )1z2Selector event loop for Unix with signal handling.� N� )�base_events)�base_subprocess)�compat)� constants)�
coroutines)�events)�futures)�selector_events)� selectors)�
transports)� coroutine)�logger�SelectorEventLoop�AbstractChildWatcher�SafeChildWatcher�FastChildWatcher�DefaultEventLoopPolicyZwin32z+Signals are not really supported on Windowsc C s dS )zDummy signal handler.N� )�signum�framer r �8/opt/alt/python36/lib64/python3.6/asyncio/unix_events.py�_sighandler_noop% s r c C s | S )Nr )�pathr r r �<lambda>. s r c s� e Zd ZdZd"� fdd� Zdd� Z� fdd�Zd d
� Zdd� Zd
d� Z dd� Z
dd� Zd#dd�Zd$dd�Z
ed%dd��Zdd� Zedddd�dd��Zed&dddd�d d!��Z� ZS )'�_UnixSelectorEventLoopzdUnix event loop.
Adds signal handling and UNIX Domain Socket support to SelectorEventLoop.
Nc s t � j|� i | _d S )N)�super�__init__�_signal_handlers)�self�selector)� __class__r r r 7 s z_UnixSelectorEventLoop.__init__c C s t j� S )N)�socketZ
socketpair)r r r r �_socketpair; s z"_UnixSelectorEventLoop._socketpairc s^ t � j� tj� s2xFt| j�D ]}| j|� qW n(| jrZtjd| �d�t | d� | jj
� d S )NzClosing the loop z@ on interpreter shutdown stage, skipping signal handlers removal)�source)r �close�sys�
is_finalizing�listr �remove_signal_handler�warnings�warn�ResourceWarning�clear)r �sig)r! r r r% >