AlkantarClanX12

Your IP : 3.21.248.105


Current Path : /opt/alt/python312/lib64/python3.12/multiprocessing/__pycache__/
Upload File :
Current File : //opt/alt/python312/lib64/python3.12/multiprocessing/__pycache__/reduction.cpython-312.opt-2.pyc

�

�Q�f(%��f�ddlmZddlZddlZddlZddlZddlZddlZddlZddl	m
Z
gd�Zejdk(xs)e
ed�xre
ed�xre
ejd	�ZGd
�dej�Zej"Zd)d�Zejdk(r'egd
�z
ZddlZd*dd�d�Zd�Zd�Zd�ZGd�de�Zn)egd�z
ZddlZejdk(Zd�Zd�Zd�Zd�Zd�Zd�ZGd�d�Z ee!e �jD�e�d�Z#ee!e$jJ�e#�ee!e&jN�e#�d �Z(d!�Z)eejTe(�ejdk(rd"�Z+d#�Z,eeje+�nd$�Z+d%�Z,eeje+�Gd&�d'e�(�Z-y)+�)�ABCMetaN�)�context)�send_handle�recv_handle�ForkingPickler�register�dump�win32�CMSG_LEN�
SCM_RIGHTS�sendmsgc�v��eZdZ	iZej
Z�fd�Zed��Z	edd��Z
ejZ�xZ
S)rc���t�|�|�|jj�|_|jj|j�y�N)�super�__init__�_copyreg_dispatch_table�copy�dispatch_table�update�_extra_reducers)�self�args�	__class__s  ��@/opt/alt/python312/lib64/python3.12/multiprocessing/reduction.pyrzForkingPickler.__init__&sA���
���$��"�:�:�?�?�A������"�"�4�#7�#7�8�c�$�	||j|<yr)r)�cls�type�reduces   rr	zForkingPickler.register+s��4�$*����D�!rc�z�tj�}|||�j|�|j�Sr)�io�BytesIOr
�	getbuffer)r�obj�protocol�bufs    r�dumpszForkingPickler.dumps0s.���j�j�l���C������$��}�}��rr)�__name__�
__module__�__qualname__r�copyregrrr�classmethodr	r)�pickle�loads�
__classcell__)rs@rrr!sO���3��O�%�4�4��9�
�+��+�����

�L�L�Errc�<�	t||�j|�yr)rr
)r&�filer's   rr
r
:s��=��4��"�'�'��,r)�	DupHandle�	duplicate�steal_handle)�source_processc��	tj�}|�|}|�|}tj|||d|tj�S)Nr)�_winapi�GetCurrentProcess�DuplicateHandle�DUPLICATE_SAME_ACCESS)�handle�target_process�inheritabler7�current_processs     rr5r5GsP��J�!�3�3�5���!�,�N��!�,�N��&�&��F�N�
�{�G�9�9�;�	;rc	�D�	tjtjd|�}	tj||tj�ddtj
tjz�tj|�S#tj|�wxYw�NFr)r9�OpenProcess�PROCESS_DUP_HANDLEr;r:r<�DUPLICATE_CLOSE_SOURCE�CloseHandle)�
source_pidr=�source_process_handles   rr6r6Ss���C� '� 3� 3��&�&��z�!;��	7��*�*�%�v��)�)�+�Q���-�-��0N�0N�N�P�

��� 5�6��G��� 5�6�s�A
B�Bc�^�	t|tj|�}|j|�yr)r4r9r<�send)�connr=�destination_pid�dhs    rrr_s$��4�
�v�w�<�<�o�
N���	�	�"�
rc�@�	|j�j�Sr)�recv�detach)rKs rrrds��7��y�y�{�!�!�#�#rc��eZdZ	dd�Zd�Zy)r4Nc�X�|�tj�}tjtjd|�}	tj
tj�|||dd�|_tj|�||_	||_
y#tj|�wxYwrB)�os�getpidr9rCrDr;r:�_handlerF�_access�_pid)rr=�access�pid�procs     rrzDupHandle.__init__js����{��i�i�k���&�&�w�'A�'A�5�#�N�D�
*�&�6�6��-�-�/��D�&�%�� 4����#�#�D�)�!�D�L��D�I���#�#�D�)�s�1B�B)c��	|jtj�k(r|jSt	j
tjd|j�}	t	j||jt	j�|jdtj�t	j|�S#t	j|�wxYw�NF)rWrSrTrUr9rCrDr;r:rVrErF)rrZs  rrPzDupHandle.detachys���C��y�y�B�I�I�K�'��|�|�#��&�&�w�'A�'A�5�'+�y�y�2�D�
*��.�.��$�,�,��(A�(A�(C��L�L�%��)G�)G�I��#�#�D�)���#�#�D�)�s
�A
C�Cr)r*r+r,rrP�rrr4r4hs��-�
	�	*rr4)�DupFd�sendfds�recvfds�darwinc��	tjd|�}tt|�dzg�}|j|gtj
tj|fg�tr |jd�dk7rtd��yy)N�i�r�Az%did not receive acknowledgement of fd)
�array�bytes�lenr�socket�
SOL_SOCKETr
�ACKNOWLEDGErO�RuntimeError)�sock�fds�msgs   rr_r_�su��:��k�k�#�s�#���S��X��^�$�%�����c�U�f�/�/��1B�1B�C�H�I�J��4�9�9�Q�<�4�/��F�G�G�0�;rc���	tjd�}|j|z}|jdtj|��\}}}}|s|st
�	tr|jd�t|�dk7rtdt|�z��|d\}}	}
|tjk(r�|	tjk(rxt|
�|jzdk7rt�|j|
�t|�dz|dk7r'tdjt|�|d���t!|�Std��#tt"f$r
Ytd��wxYw)	Nrcrrezreceived %d items of ancdatarrdz Len is {0:n} but msg[0] is {1!r}zInvalid data received)rf�itemsize�recvmsgri�
CMSG_SPACE�EOFErrorrkrJrhrlrjr
�
ValueError�	frombytes�AssertionError�format�list�
IndexError)rm�size�a�
bytes_sizero�ancdata�flags�addr�
cmsg_level�	cmsg_type�	cmsg_datas           rr`r`�sW��=��K�K�����Z�Z�$�&�
�$(�L�L��F�4E�4E�j�4Q�$R�!��W�e�T��7��N�	���	�	�$���7�|�q� �"�#A�#&�w�<�$0�1�1�/6�q�z�,�J�	�9��f�/�/�/��V�.�.�.��y�>�A�J�J�.�!�3�$�$����I�&��q�6�C�<�3�q�6�)�(�:�A�A���F�C��F�,�-�-��A�w���2�3�3���J�'�	���2�3�3�	�s�C"E	�	E%�$E%c���	tj|j�tjtj�5}t||g�ddd�y#1swYyxYwr)ri�fromfd�fileno�AF_UNIX�SOCK_STREAMr_)rKr=rL�ss    rrr�sA��4�
�]�]�4�;�;�=�&�.�.�&�:L�:L�
M�QR��A��x� �N�
M�
M�s�A�A#c���	tj|j�tjtj�5}t|d�dcddd�S#1swYyxYw)Nrr)rir�r�r�r�r`)rKr�s  rrr�sG��7�
�]�]�4�;�;�=�&�.�.�&�:L�:L�
M�QR��1�a�=��#�	$�	$�
M�
M�s�A�A%c��	tj�}|� |j|j|��Strddlm}|j|�Std��)Nr)�resource_sharerz&SCM_RIGHTS appears not to be available)r�get_spawning_popenr^�duplicate_for_child�HAVE_SEND_HANDLE�r�ru)�fd�	popen_objr�s   rr^r^�sV��)��.�.�0�	�� ��?�?�9�#@�#@��#D�E�E�
�)�"�(�(��,�,��E�F�Frc��|j�(t|j|jjffSt|j|jjffSr)�__self__�getattrr�__func__r*��ms r�_reduce_methodr��sH���z�z������a�j�j�&9�&9�:�:�:�����Q�Z�Z�%8�%8�9�9�9rc��eZdZd�Zy)�_Cc��yrr])rs r�fz_C.f�s��rN)r*r+r,r�r]rrr�r��s��
rr�c�>�t|j|jffSr)r��__objclass__r*r�s r�_reduce_method_descriptorr��s���Q�^�^�Q�Z�Z�0�0�0rc�\�t|j|j|jxsiffSr)�_rebuild_partial�funcr�keywords)�ps r�_reduce_partialr��s%���a�f�f�a�f�f�a�j�j�.>�B�?�?�?rc�4�tj|g|��i|��Sr)�	functools�partial)r�rr�s   rr�r��s�����T�5�D�5�H�5�5rc�,�ddlm}t||�ffS)Nr)�	DupSocket)r�r��_rebuild_socket)r�r�s  r�_reduce_socketr��s��.���1���/�/rc�"�|j�Sr)rP)�dss rr�r��s���y�y�{�rc��t|j��}t||j|j|j
ffSr)r^r�r��familyr �proto)r��dfs  rr�r��s2��
�1�8�8�:�
����Q�X�X�q�v�v�q�w�w� ?�?�?rc�T�|j�}tj||||��S)N)r�)rPri)r�r�r r�r�s     rr�r��s"��
�Y�Y�[���}�}�V�T�5��<�<rc�t�eZdZ	eZeZeZeZeZejdk(re
Z
eZeZne
Z
eZeZeZeZeZeZeZd�Zy)�AbstractReducerrc�n�ttt�j�t�ttt
j�t�tttj�t�ttjt�ttjt�yr)r	r r�r�r�ry�appendr��int�__add__r�r�r�rir�)rrs  rrzAbstractReducer.__init__s\����b�d�f�f��~�.���d�k�k�"�$=�>���c�k�k�"�$=�>���"�"�O�4������/rN)r*r+r,rr	r
rr�sys�platformr6r5r4r_r`r^r�r�r�r�r�rr]rrr�r��sl�� �$�N��H��D��K��K�
�|�|�w��#���	��	�������#�N� 9��'��#�N�%�O�0rr�)�	metaclassrr\).�abcrr-r�r#rSr/rir�r�r�__all__r��hasattrr��Picklerrr	r
r9r5r6rr�objectr4rfrkr_r`r^r�r�r r�r�ryr�r�r�r�r�r�r�r�r�r]rr�<module>r�s������	�	�
�
�
��
N���L�L�G�+�8��V�Z�0�7��V�\�2�7��V�]�]�I�6���V�^�^��.�"�"��-��<�<�7���9�9�G��
;�$(�
;�
7��
$�*�F�*�F�.�.�G���,�,�(�*�K�H�4�8!�
$�
	G�:�

�
�	��b�d�f�f��~�&�1���d�k�k�	�5�6���c�k�k�	�5�6�@�6���	�	�O�,��<�<�7��0���V�]�]�N�+�@�=�
�V�]�]�N�+�0��0r