KGRKJGETMRETU895U-589TY5MIGM5JGB5SDFESFREWTGR54TY
Server : Apache
System : Linux cs317.bluehost.com 4.19.286-203.ELK.el7.x86_64 #1 SMP Wed Jun 14 04:33:55 CDT 2023 x86_64
User : andertr9 ( 1047)
PHP Version : 8.2.18
Disable Function : NONE
Directory :  /lib64/python2.7/site-packages/mercurial/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //lib64/python2.7/site-packages/mercurial/lock.pyc
�
Hq�Qc@swddlZddlZddlZddlZddlZddlZddlZdefd��YZd�Z	dS(i����NtlockcBsSeZdZdZdddd�Zd�Zd�Zd�Zd�Z	d�Z
RS(	s�An advisory lock held by one process to control access to a set
    of files.  Non-cooperating processes or incorrectly written scripts
    can ignore Mercurial's locking scheme and stomp all over the
    repository, so don't do that.

    Typically used via localrepository.lock() to lock the repository
    store (.hg/store/) or localrepository.wlock() to lock everything
    else under .hg/.i����cCsS||_d|_||_||_||_g|_tj�|_|j	�dS(Ni(
tftheldttimeoutt	releasefntdesctpostreleasetostgetpidtpidR(tselftfileRRR((s4/usr/lib64/python2.7/site-packages/mercurial/lock.pyt__init__ s						cCs<|jr.tjddtdd�d|_n|j�dS(Ns$use lock.release instead of del locktcategoryt
stacklevelii(RtwarningstwarntDeprecationWarningtrelease(R
((s4/usr/lib64/python2.7/site-packages/mercurial/lock.pyt__del__*s	cCs�|j}x�tr�y|j�dSWqtjk
r�}|dkrqtjd�|dkr|d8}qqntjtj|j	|j
|j��qXqWdS(Nii(RtTruettrylockterrortLockHeldttimetsleepterrnot	ETIMEDOUTtfilenameRtlocker(R
Rtinst((s4/usr/lib64/python2.7/site-packages/mercurial/lock.pyR6s		


cCs|jr|jd7_dStjdkr=tj�t_ndtj|jf}x�|jsy tj||j	�d|_WqVt
tfk
r}|jtj
kr�|j�}|dk	rtjtj|j	|j|��qqtj|j|j|j|j��qVXqVWdS(Nis%s:%s(RRt_hosttNonetsockettgethostnameR	tutiltmakelockRtOSErrortIOErrorRtEEXISTttestlockRRtEAGAINRtLockUnavailabletstrerrorR(R
tlocknametwhyR((s4/usr/lib64/python2.7/site-packages/mercurial/lock.pyREs$	
cCsytj|j�}Wn,tk
rD}|jtjkr>dS�nXy|jdd�\}}Wntk
ru|SX|t	j
kr�|Syt|�}Wntk
r�|SXtj|�r�|Sy7t	|jddd�}tj
|j�|j�Wntjk
r|SXdS(soreturn id of locker if lock is valid, else None.

        If old-style lock, we cannot tell what machine locker is on.
        with new-style lock, if locker is on this machine, we can
        see if locker is alive.  If locker is on this machine but
        not alive, we can safely break lock.

        The lock file is only deleted when None is returned.

        t:is.breakRiN(R#treadlockRR%RtENOENTR tsplitt
ValueErrorRRtintttestpidtunlinkRRt	LockError(R
RR-thostR	tl((s4/usr/lib64/python2.7/site-packages/mercurial/lock.pyR(Zs0

cCs�|jdkr!|jd8_n�|jdkr�d|_tj�|jkrRdS|jrh|j�nytj|j�Wntk
r�nXx|j	D]
}|�q�WndS(s�release the lock and execute callback function if any

        If the lock has been acquired multiple times, the actual release is
        delayed to the last release call.iiN(
RRRR	RR#R5RR%R(R
tcallback((s4/usr/lib64/python2.7/site-packages/mercurial/lock.pyR�s		

N(t__name__t
__module__t__doc__R RRRRRR(R(((s4/usr/lib64/python2.7/site-packages/mercurial/lock.pyRs

				&cGs.x'|D]}|dk	r|j�qqWdS(N(R R(tlocksR((s4/usr/lib64/python2.7/site-packages/mercurial/lock.pyR�s
(
R#RRRR!RRtobjectRR(((s4/usr/lib64/python2.7/site-packages/mercurial/lock.pyt<module>s0�

Anon7 - 2021