Your IP : 18.119.28.173


Current Path : /opt/hc_python/share/doc/pycurl/examples/__pycache__/
Upload File :
Current File : //opt/hc_python/share/doc/pycurl/examples/__pycache__/file_upload.cpython-38.pyc

U

hf��@s�ddlZddlZddlZGdd�d�Zeej�dkrJedejd�e�ejdZejdZ	ej
�e	�szede	�e�e��Z
e
�eje�e
�ejd�e
�ejeee	d	��j�ej
�e	�Ze
�eje�ed
e	ef�e
��e
��dS)�Nc@seZdZdd�Zdd�ZdS)�
FileReadercCs
||_dS�N)�fp)�selfr�r�^/opt/hc_python/lib64/python3.8/site-packages/../../../share/doc/pycurl/examples/file_upload.py�__init__
szFileReader.__init__cCs|j�|�Sr)r�read)r�sizerrr�
read_callbackszFileReader.read_callbackN)�__name__�
__module__�__qualname__rrrrrrr	sr�z Usage: %s <url> <file to upload>��z#Error: the file '%s' does not exist�rbzUploading file %s to url %s)�os�sysZpycurlr�len�argv�print�
SystemExit�url�filename�path�existsZCurl�cZsetopt�URLZUPLOADZREADFUNCTION�openr�getsize�filesizeZ
INFILESIZEZperform�closerrrr�<module>s&



?>