%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /opt/alt/python311/lib64/python3.11/__pycache__/
Upload File :
Create Path :
Current File : //opt/alt/python311/lib64/python3.11/__pycache__/imghdr.cpython-311.pyc

�

c��fp����dZddlmZddlZdgZejed���dd�ZgZd�Z	e�
e	��d	�Ze�
e��d
�Ze�
e��d�Z
e�
e
��d�Ze�
e��d
�Ze�
e��d�Ze�
e��d�Ze�
e��d�Ze�
e��d�Ze�
e��d�Ze�
e��d�Ze�
e��d�Ze�
e��d�Zd�Zedkre��dSdS)z<Recognize image file formats based on their first few bytes.�)�PathLikeN�what)��
)�removec���d}	|��t|ttf��r&t|d��}|�d��}n>|���}|�d��}|�|��tD]+}|||��}|r|c|r|���SS�,	|r|���n#|r|���wwxYwdS)N�rb� )	�
isinstance�strr�open�read�tell�seek�tests�close)�file�h�f�location�tf�ress      �-/opt/alt/python311/lib64/python3.11/imghdr.pyrrs����A���9��$��h��0�0�
$���t�$�$���F�F�2�J�J����9�9�;�;���I�I�b�M�M���	�	�(�#�#�#��	�	�B��"�Q��(�(�C��
��
�
���a�g�g�i�i�i�i��
�	�

��a�g�g�i�i�i���1��a�g�g�i�i�i�i������4s�BC�8C�C*c�B�|dd�dvrdS|dd�dkrdSdS)z1JPEG data with JFIF or Exif markers; and raw JPEG��
)sJFIFsExif�jpegN�s��۩�rrs  r�	test_jpegr!*s<����2��w�$�$�$��v�	
�2�A�2��%�	%�	%��v�
&�	%�c�4�|�d��rdSdS)Ns�PNG

�png��
startswithr s  r�test_pngr'3s&���|�|�(�)�)���u��r"c�"�|dd�dvrdSdS)zGIF ('87 and '89 variants)Nr)sGIF87asGIF89a�gifrr s  r�test_gifr*9s#����!��u�&�&�&��u�'�&r"c�"�|dd�dvrdSdS)z-TIFF (can be in Motorola or Intel byte order)N�)sMMsII�tiffrr s  r�	test_tiffr.@s"����!��u�����v��r"c�4�|�d��rdSdS)zSGI image librarys��rgbNr%r s  r�test_rgbr1G�%���|�|�K� � ���u��r"c��t|��dkr/|dtd��kr|ddvr|ddvrdSd	Sd	Sd	Sd	S)
zPBM (portable bitmap)rr�P�s14r,� 	

�pbmN��len�ordr s  r�test_pbmr;N�\��
�1�v�v��{�{�	�!���D�	�	���a��d�e�m�m��!��
�0B�0B��u��{���m�m�0B�0Br"c��t|��dkr/|dtd��kr|ddvr|ddvrdSd	Sd	Sd	Sd	S)
zPGM (portable graymap)rrr4r5s25r,r6�pgmNr8r s  r�test_pgmr?Vr<r"c��t|��dkr/|dtd��kr|ddvr|ddvrdSd	Sd	Sd	Sd	S)
zPPM (portable pixmap)rrr4r5s36r,r6�ppmNr8r s  r�test_ppmrB^r<r"c�4�|�d��rdSdS)zSun raster filesY�j��rastNr%r s  r�	test_rastrEfs&���|�|�'�(�(���v��r"c�4�|�d��rdSdS)zX bitmap (X10 or X11)s#define �xbmNr%r s  r�test_xbmrHmr2r"c�4�|�d��rdSdS)NsBM�bmpr%r s  r�test_bmprKts%���|�|�E�����u��r"c�T�|�d��r|dd�dkrdSdSdS)NsRIFF��sWEBP�webpr%r s  r�	test_webprPzs=���|�|�G�����1�R�4��G�!3�!3��v���!3�!3r"c�4�|�d��rdSdS)Nsv/1�exrr%r s  r�test_exrrS�s&���|�|�'�(�(���u��r"c�n�ddl}d}|jdd�r|jddkr|jdd�=d}	|jdd�r t|jdd�|d��dStdg|d��dS#t$r3|j�d��|�d��YdSwxYw)Nrr5z-rr,�.z
[Interrupted]
)�sys�argv�testall�KeyboardInterrupt�stderr�write�exit)rV�	recursives  r�testr^�s����J�J�J��I�
�x����|������t�+�+��H�Q�q�S�M��	���8�A�B�B�<�	)��C�H�Q�R�R�L�)�Q�/�/�/�/�/��S�E�9�a�(�(�(�(�(�������
���,�-�-�-��������������s�-A7�#A7�79B4�3B4c�F�ddl}ddl}|D�]}|j�|��r�t	|dzd���|s|rft	d��ddl}|�|j�|�|��d����}t||d����t	d����t	|dzd���|j	�
��	t	t|������#t$rt	d	��Y��wxYwdS)
Nrz/:� )�endzrecursing down:�*z*** directory (use -r) ***�:z*** not found ***)
rV�os�path�isdir�print�glob�join�escaperX�stdout�flushr�OSError)�listr]�toplevelrVrd�filenamerh�namess        rrXrX�sL���J�J�J�
�I�I�I��+�+��
�7�=�=��"�"�	+��(�T�/�s�+�+�+�+��
4�H�
4��'�(�(�(������	�	�"�'�,�,�t�{�{�8�/D�/D�c�"J�"J�K�K����y�!�,�,�,�,��2�3�3�3�3��(�S�.�c�*�*�*�*��J������
+��d�8�n�n�%�%�%�%���
+�
+�
+��)�*�*�*�*�*�
+����+�+s�$D�D�D�__main__)N)�__doc__rdr�warnings�__all__�_deprecated�__name__rrr!�appendr'r*r.r1r;r?rBrErHrKrPrSr^rXrr"r�<module>rysk��B�B������������(�����X�g�.�.�.�.�����0	��������Y����������X�������
���X�������
���Y�������
���X����������X����������X����������X�������
���Y�������
���X����������X����������Y����������X����
�
�
�+�+�+�*�z����D�F�F�F�F�F��r"

Zerion Mini Shell 1.0