https://t.me/RX1948
Server : Apache
System : Linux iad1-shared-b8-43 6.6.49-grsec-jammy+ #10 SMP Thu Sep 12 23:23:08 UTC 2024 x86_64
User : dh_edsupp ( 6597262)
PHP Version : 8.2.26
Disable Function : NONE
Directory :  /lib/python3/dist-packages/trac/util/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //lib/python3/dist-packages/trac/util/__pycache__/daemon.cpython-310.pyc
o

�k�`��@sBddlZddlZddlZddlZddlZ		ddd�Zdd�ZdS)	�N�	/dev/null�c
s��r�tj����tj���rrt�d��!}zt|���}Wnty,t�	d��YnwWd�n1s7wYzt�
|d�|sNtj�tjd�}t�	d||f�Wnt
yq}z
|jtjkrg�WYd}~nd}~wwzt�d��Wd�n1s�wYWn!ty�}zddlm}	t�	d|	|��WYd}~nd}~wwt��}|dkr�t�	d�t�d	�t�|�t��t��}|dkr�t�	d�tjtjfD]}
|
��q�t�|tj�}t�|tjtjB�}t�|tjtjB�}t�|tj���t�|tj���t�|tj���|||fD]}t� |��q��rdt!j"t!j#fD]	}t!�!|t$��q-�fd
d�}
t%�&|
�t�d��}|�'d
t�(��Wd�dS1�s]wYdSdS)zFork a daemon process.�rbz2Invalid pid in file %s
Please remove it to proceedNrz!%s is already running with pid %sza+)�exception_to_unicodezError writing to pid file: %s�/cstj���r
t���dSdS)N)�os�path�exists�remove���pidfiler�2/usr/lib/python3/dist-packages/trac/util/daemon.py�remove_pidfileWs�z!daemonize.<locals>.remove_pidfile�wbs%d))rr�abspathr	�open�int�read�
ValueError�sys�exit�kill�basename�argv�OSError�errno�ESRCH�IOError�trac.util.textr�fork�chdir�umask�setsid�stdout�stderr�flush�O_RDONLY�O_RDWR�O_APPEND�dup2�stdin�fileno�close�signal�SIGTERM�SIGHUP�
handle_signal�atexit�register�write�getpid)r
�prognamer+r$r%r"�fileobj�pid�er�stream�fd�signumrrrr�	daemonizes|
�����������





$��r=cCst��dS)z.Handle signals sent to the daemonized process.N)rr)r<�framerrrr1_sr1)NNrrrr)r2rrr.rr=r1rrrr�<module>s

�J

https://t.me/RX1948 - 2025