MCPcopy Create free account
hub / github.com/acl-dev/acl / read_respond_hdr_timeout

Function read_respond_hdr_timeout

app/jaws/module/mod_http/http_proxy.c:615–653  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

613}
614
615static int read_respond_hdr_timeout(ACL_ASTREAM *server, void *ctx)
616{
617 const char *myname = "read_respond_hdr_timeout";
618 HTTP_CLIENT *http_client = (HTTP_CLIENT *) ctx;
619
620 /* ȡ��������������״̬ */
621 http_client->flag &= ~HTTP_FLAG_SERVER_LOCKED;
622
623 /* ȡ�� HTTP ��Ӧͷ�Ķ��رջص����� */
624 acl_aio_clean_close_hooks(server);
625
626 if (http_client->entry.client == NULL) {
627 acl_msg_warn("%s(%d): client null", myname, __LINE__);
628 http_proxy_complete(http_client, -1);
629 /* ���뷵�� -1, ��Ϊ��ϣ���������������ij�ʱ�ص����� */
630 return (-1);
631 }
632
633 /* �������� */
634 if (http_request_reforward(http_client) == 0) {
635 /* ����Ѿ���ʼ���Թ��̣���ֱ�ӷ��� */
636 /* ���뷵�� -1, ��Ϊ��ϣ���������������ij�ʱ�ص����� */
637 return (-1);
638 }
639
640 /* �����ͻ����� */
641 http_client->flag |= HTTP_FLAG_CLIENT_LOCKED;
642
643 /* ���ظ��ͻ��˶��������Ӧ��ʱ��Ϣ */
644 acl_aio_writen(http_client->entry.client,
645 HTTP_REPLY_TIMEOUT, (int) strlen(HTTP_REPLY_TIMEOUT));
646
647 /* �����ͻ����� */
648 http_client->flag &= ~HTTP_FLAG_CLIENT_LOCKED;
649
650 http_proxy_complete(http_client, -1);
651 /* ���뷵�� -1, ��Ϊ��ϣ���������������ij�ʱ�ص����� */
652 return (-1);
653}
654
655static int read_respond_hdr_error(ACL_ASTREAM *server acl_unused, void *ctx)
656{

Callers

nothing calls this directly

Calls 5

acl_msg_warnFunction · 0.85
http_proxy_completeFunction · 0.85
http_request_reforwardFunction · 0.85
acl_aio_writenFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…