§
    dJ  ã                   ó´   — d dl Z d dlZddlmZ 	 e j        Zn# e$ r
 e j        ZY nw xY w eed¬¦  «        Zd„ Z	d„ Z
 G d„ d	e¦  «        Zdd„Zd„ Zd„ Zd„ ZdS )é    Né   )ÚBufferi   )Úlimitc                 ó„   — t          | t          ¦  «        rt          | ¦  «        } |                      d¦  «        dd…         S )zMsplit a list of zero-terminated strings into python not-zero-terminated bytesó    Néÿÿÿÿ)Ú
isinstanceÚ	bytearrayÚbytesÚsplit)Úbufs    ú5/usr/lib/python3/dist-packages/borg/platform/xattr.pyÚsplit_string0r      s:   € å�#•yÑ!Ô!ð Ý�C‰jŒjˆØ�9Š9�UÑÔ˜C˜R˜CÔ Ð ó    c                 ó´   — g }t          | ¦  «        }|rD|d         }|                     t          |dd|z   …         ¦  «        ¦  «         |d|z   d…         }|°D|S )zMsplit a list of length-prefixed strings into python not-length-prefixed bytesr   é   N)Ú
memoryviewÚappendr   )r   ÚresultÚmvÚlengths       r   Úsplit_lstringr      sl   € à€FÝ	�C‰Œ€BØ
ð Ø�A”ˆØ�Š•e˜B˜q  V¡˜|Ô,Ñ-Ô-Ñ.Ô.Ð.Ø��F‘
��Œ_ˆð ð ð €Mr   c                   ó   — e Zd ZdZdS )ÚBufferTooSmallErrorzBthe buffer given to a xattr function was too small for the result.N)Ú__name__Ú
__module__Ú__qualname__Ú__doc__© r   r   r   r   #   s   € € € € € ØLÐLÐLÐLr   r   Fc                 óL  — ddl m} | dk     rv |¦   «         }|r|t          j        k    rt          ‚	 t          j        |¦  «        }n# t          $ r d}Y nw xY wt          |t          ¦  «        rd|z  }t          |||¦  «        ‚|r| t          t          ¦  «        k    rt          ‚| S )Nr   )Ú	get_errnor   Ú z<FD %d>)r"   r!   ÚerrnoÚERANGEr   ÚosÚstrerrorÚ
ValueErrorr	   ÚintÚOSErrorÚlenÚbuffer)ÚrvÚpathÚdetect_buffer_too_smallr!   ÚeÚmsgs         r   Ú_checkr1   '   sÏ   € ØÐÐÐÐÐØ	ˆA‚v€vØˆI‰KŒKˆØ"ð 	( q­E¬LÒ'8Ð'8õ &Ð%ðÝ”k !‘n”n��øÝð ð ð Ø���ðøøøå˜$¥Ñ$Ô$ð (Ø  4Ñ'�Ý˜!˜S $Ñ'Ô'Ð'Øð " 2­­V©¬Ò#4Ð#4õ
 "Ð!Ø€Is   ±A ÁAÁAc                 ó  — t          |t          t          f¦  «        sJ ‚t          t          ¦  «        }	 t                               |¦  «        }	 t           | |||¦  «        |d¬¦  «        }||fS # t          $ r |dz  }Y nw xY wŒR©NT©r.   r   ©r	   r   r(   r*   r+   Úgetr1   r   )Úfuncr-   Úsizer   Úns        r   Ú_listxattr_innerr:   @   sž   € Ý�d�U¥C˜LÑ)Ô)Ð)Ð)Ð)Ý�v‰;Œ;€DðÝ�jŠj˜ÑÔˆð	Ý�t�t˜D # tÑ,Ô,¨dÈDÐQÑQÔQˆAð �c�6ˆMøõ #ð 	ð 	ð 	Ø�A‰IˆDˆDˆDð	øøøð	s   ÁA0 Á0BÂBc                 ó<  — t          |t          t          f¦  «        sJ ‚t          |t          ¦  «        sJ ‚t          t          ¦  «        }	 t                               |¦  «        }	 t           | ||||¦  «        |d¬¦  «        }||fS # t          $ r |dz  }Y nw xY wŒSr3   r5   )r7   r-   Únamer8   r   r9   s         r   Ú_getxattr_innerr=   M   s·   € Ý�d�U¥C˜LÑ)Ô)Ð)Ð)Ð)Ý�d�EÑ"Ô"Ð"Ð"Ð"Ý�v‰;Œ;€DðÝ�jŠj˜ÑÔˆð	Ý�t�t˜D $¨¨TÑ2Ô2°DÐRVÐWÑWÔWˆAð �c�6ˆMøõ #ð 	ð 	ð 	Ø�A‰IˆDˆDˆDð	øøøð	s   Á&B ÂBÂBc           
      óô   — t          |t          t          f¦  «        sJ ‚t          |t          ¦  «        sJ ‚t          |t          ¦  «        sJ ‚t           | |||t	          |¦  «        ¦  «        |d¬¦  «         d S )NFr4   )r	   r   r(   r1   r*   )r7   r-   r<   Úvalues       r   Ú_setxattr_innerr@   [   sy   € Ý�d�U¥C˜LÑ)Ô)Ð)Ð)Ð)Ý�d�EÑ"Ô"Ð"Ð"Ð"Ý�e�UÑ#Ô#Ð#Ð#Ð#Ý
ˆ4ˆ4��d˜E¥3 u¡:¤:Ñ.Ô.°ÈeÐTÑTÔTÐTÐTÐTr   )NF)r#   r%   Úhelpersr   ÚENOATTRÚAttributeErrorÚENODATAr
   r+   r   r   Ú	Exceptionr   r1   r:   r=   r@   r   r   r   ú<module>rF      s  ðØ €€€Ø 	€	€	€	à Ð Ð Ð Ð Ð ðØŒm€G€GøØð ð ð àŒm€G€G€Gðøøøð
 
ˆ�	 Ð	'Ñ	'Ô	'€ð!ð !ð !ðð ð ðMð Mð Mð Mð M˜)ñ Mô Mð Mðð ð ð ð2
ð 
ð 
ðð ð ðUð Uð Uð Uð Us   � ˜'¦'