MCPcopy Create free account
hub / github.com/3rdparty/libprocess / on_message_begin

Method on_message_begin

src/decoder.hpp:598–616  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

596
597private:
598 static int on_message_begin(http_parser* p)
599 {
600 StreamingResponseDecoder* decoder = (StreamingResponseDecoder*) p->data;
601
602 CHECK(!decoder->failure);
603
604 decoder->header = HEADER_FIELD;
605 decoder->field.clear();
606 decoder->value.clear();
607
608 CHECK(decoder->response == nullptr);
609 CHECK_NONE(decoder->writer);
610
611 decoder->response = new http::Response();
612 decoder->response->type = http::Response::PIPE;
613 decoder->writer = None();
614
615 return http_parsing::SUCCESS;
616 }
617
618 static int on_chunk_complete(http_parser* p)
619 {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected