
    nf6                     X    d dl mZ d dlmZmZ  G d d          Z G d de          ZdS )    )Request)SocketUnreaderIterUnreaderc                   (    e Zd ZdZd Zd Zd ZeZdS )ParserNc                     || _         t          |d          rt          |          | _        nt	          |          | _        d | _        || _        d| _        d S )Nrecvr   )cfghasattrr   unreaderr   mesgsource_addr	req_count)selfr
   sourcer   s       S/var/www/surfInsights/venv3-11/lib/python3.11/site-packages/gunicorn/http/parser.py__init__zParser.__init__   sW    66"" 	1*622DMM(00DM	&     c                     | S )N )r   s    r   __iter__zParser.__iter__   s    r   c                    | j         r'| j                                         rt                      | j         rB| j         j                            d          }|r!| j         j                            d          }|!| xj        dz  c_        |                     | j        | j        | j	        | j                  | _         | j         st                      | j         S )Ni       )
r   should_closeStopIterationbodyreadr   
mesg_classr
   r   r   )r   datas     r   __next__zParser.__next__   s    9 	"//11 	"//! 9 	19>&&t,,D 1y~**400  1 	!OODHdmT=Mt~^^	y 	"//!yr   )__name__
__module____qualname__r   r   r   r    nextr   r   r   r   r   	   sG        J
 
 
    $ DDDr   r   c                       e Zd ZeZdS )RequestParserN)r!   r"   r#   r   r   r   r   r   r&   r&   1   s        JJJr   r&   N)gunicorn.http.messager   gunicorn.http.unreaderr   r   r   r&   r   r   r   <module>r)      s   
 * ) ) ) ) ) ? ? ? ? ? ? ? ?% % % % % % % %P    F     r   