HEX
Server: Apache/2.4.65 (Debian)
System: Linux kubikelcreative 5.10.0-35-amd64 #1 SMP Debian 5.10.237-1 (2025-05-19) x86_64
User: www-data (33)
PHP: 8.4.13
Disabled: NONE
Upload Files
File: //usr/lib/python3/dist-packages/cloudinit/__pycache__/signal_handler.cpython-39.pyc
a

��`4�@s�ddlZddlZddlZddlmZddlmZddlmZddlm	Z
e�e�Z
dZejdejdejd	iZd
d�Zdd
�Zdd�ZdS)�N)�StringIO)�log)�util)�version�)z2Cloud-init %(version)s received SIGINT, exiting...�)z3Cloud-init %(version)s received SIGTERM, exiting...r)z3Cloud-init %(version)s received SIGABRT, exiting...rcCsz||ks|sdSt�|�}d|d}|�d||jf�|�d||jf�|�d||jf�t|j|d||�dS)N� �z%sFilename: %s
z%sFunction: %s
z%sLine number: %s
r)�inspect�getframeinfo�write�filename�function�lineno�
_pprint_frame�f_back)�frame�depthZ	max_depth�contentsZ
frame_info�prefix�r�:/usr/lib/python3/dist-packages/cloudinit/signal_handler.pyrs
rcCsbt|\}}|dt��i}t�}|�d|�t|dt|�tj|�	�ddt
d�t�|�dS)Nrz%s
rTF)�console�stderrr)
�EXIT_FOR�vr�version_stringrrr�BACK_FRAME_TRACE_DEPTHr�	multi_log�getvalue�LOG�sys�exit)�signumr�msg�rcrrrr�_handle_exit*s
�r&cCs.d}t��D]}t�|t�q|tt�7}|S)Nr)r�keys�signalr&�len)Z
sigs_attachedr#rrr�attach_handlers5s
r*)r
r(r!�ior�	cloudinitr�loggingrrr�	getLogger�__name__r r�SIGINT�SIGTERM�SIGABRTrrr&r*rrrr�<module>	s
�