�
!A?h
^ � �p � d dl Z d dlZd dlZd dlZd dlZd dlZd dlZd dlZg d�Zd\ Z Z
ZZZ
d\ ZZdZdZdZdedddfd �Zd
� Z G d� d� � Z G d
� de� � Z G d� dej � � Zd� Zd� Z G d� dej � � Z ddedefd�Z efdd�d�Z!d� Z"d� Z#e$dk r e#� � dS dS )� N)�BadGzipFile�GzipFile�open�compress�
decompress)� � � � � )r r r � � �rbc �$ � d|v rd|v rt d|��� � �n3|�t d� � �|�t d� � �|�t d� � �|� dd� � }t | t t t
j f� � rt | ||� � }nBt | d� � st | d � � rt d ||| � � }nt d
� � �d|v r+t j |� � }t j ||||� � S |S )N�t�bzInvalid mode: z0Argument 'encoding' not supported in binary modez.Argument 'errors' not supported in binary modez/Argument 'newline' not supported in binary mode� �read�writez1filename must be a str or bytes object, or a file)
�
ValueError�replace�
isinstance�str�bytes�os�PathLiker �hasattr� TypeError�io�
text_encoding�
TextIOWrapper)�filename�mode�
compresslevel�encoding�errors�newline�gz_mode�binary_files �1/opt/alt/python-internal/lib64/python3.11/gzip.pyr r s7 � ��$ �d�{�{��$�;�;��*�4�4�9�:�:�:� � ���O�P�P�P����M�N�N�N����N�O�O�O��l�l�3��#�#�G��(�S�%���5�6�6� M��x��-�@�@��� ��6� "� "� M�g�h��&@�&@� M��t�W�m�X�F�F����K�L�L�L�
�d�{�{��#�H�-�-�����X�v�w�G�G�G��� c �V � | � t j d|� � � � d S )Nz