Your IP : 3.133.153.224
�
e f�/ � @ s� d d d d d d g Z d d l Z d d l Z d d l Z d d l Z d d l m Z d d
l m Z d d l m Z d d l m
Z
y d d
l m Z m Z Wn* e
k
r� e
d d d d � � Yn Xe e d � � \ Z Z e j j Z Gd d � d e � Z Gd d � d e � Z Gd d � d e � Z Gd d � d e � Z Gd d � d e � Z Gd d � d e � Z Gd d � d e � Z Gd d � d e j � Z d S)�Lock�RLock� Semaphore�BoundedSemaphore� Condition�Event� N)�time� )�context)�process)�util)�SemLock�
sem_unlinkz*This platform lacks a functioning sem_openz( implementation, therefore, the requiredz+ synchronization primitives needed will notz function, see issue 3770.� c @ s� e Z d Z e j � Z d d � Z e d d � � Z d d � Z d d � Z
d d
� Z d d � Z d
d � Z
e d d � � Z d S)r
c
C sT | d k r t j j � } n | j � } t j d k pB | d k } xb t d � D]H } y, t j | | | | j � | � } | _
Wn t k
r� YqR XPqR Wt d � � t j
d | j � | j � t j d k r� d d � } t j | | � n | j
j d k rPd d l m }
|
| j
j � t j | t j | j
j f d
d �n d S)N�win32�fork�d zcannot find name for semaphorezcreated semlock with handle %sc S s | j j � d S)N)�_semlock�_after_fork)�obj� r �@/opt/alt/python34/lib64/python3.4/multiprocessing/synchronize.pyr H s z%SemLock.__init__.<locals>._after_forkr )�registerZexitpriorityr )r
Z_default_contextZget_contextZget_start_method�sys�platform�range�_multiprocessingr
�
_make_namer �FileExistsErrorr �debug�handle�
_make_methodsZregister_after_fork�name�semaphore_trackerr ZFinalize�_cleanup)�self�kind�value�maxvalue�ctxr"