GNU libmicrohttpd
0.9.29
|
SPDY streams handling. More...
#include "platform.h"
Go to the source code of this file.
Functions | |
int | SPDYF_stream_new (struct SPDY_Session *session) |
void | SPDYF_stream_destroy (struct SPDYF_Stream *stream) |
void | SPDYF_stream_set_flags_on_write (struct SPDYF_Response_Queue *response_queue) |
struct SPDYF_Stream * | SPDYF_stream_find (uint32_t stream_id, struct SPDY_Session *session) |
SPDY streams handling.
Definition in file stream.h.
void SPDYF_stream_destroy | ( | struct SPDYF_Stream * | stream | ) |
Destroys stream structure and whatever is in it.
stream | SPDY_Stream to destroy |
Definition at line 117 of file stream.c.
References SPDYF_Stream::headers, NULL, and SPDY_name_value_destroy().
Referenced by SPDYF_session_destroy().
struct SPDYF_Stream* SPDYF_stream_find | ( | uint32_t | stream_id, |
struct SPDY_Session * | session | ||
) |
Find and return a session's stream, based on stream's ID.
stream_id | to search for |
session | whose streams are considered |
Definition at line 159 of file stream.c.
References SPDYF_Stream::next, NULL, SPDYF_Stream::stream_id, and SPDY_Session::streams_head.
Referenced by spdyf_handler_read_data().
int SPDYF_stream_new | ( | struct SPDY_Session * | session | ) |
Reads data from session's read buffer and tries to create a new SPDY stream. This function is called after control frame's header has been read from the buffer (after the length field). If bogus frame is received the function changes the read handler of the session and fails, i.e. there is no need of further error handling by the caller.
session | SPDY_Session whose read buffer is being read |
Definition at line 32 of file stream.c.
References SPDYF_Stream::assoc_stream_id, DLL_insert, SPDYF_Stream::flag_unidirectional, SPDY_Session::frame_handler, SPDY_Session::frame_handler_cls, SPDY_Session::is_goaway_sent, SPDYF_Stream::is_in_closed, SPDYF_Stream::is_out_closed, SPDYF_Stream::is_server_initiator, SPDY_Session::last_in_stream_id, NTOH31, NULL, SPDYF_Stream::priority, SPDY_Session::read_buffer, SPDY_Session::read_buffer_beginning, SPDY_Session::read_buffer_offset, SPDYF_Stream::session, SPDYF_Stream::slot, SPDY_NO, SPDY_SYN_STREAM_FLAG_FIN, SPDY_SYN_STREAM_FLAG_UNIDIRECTIONAL, SPDY_YES, SPDYF_DEBUG, SPDYF_handler_ignore_frame(), SPDYF_INITIAL_WINDOW_SIZE, SPDYF_Stream::stream_id, SPDY_Session::streams_head, SPDY_Session::streams_tail, and SPDYF_Stream::window_size.
Referenced by spdyf_handler_read_syn_stream().
void SPDYF_stream_set_flags_on_write | ( | struct SPDYF_Response_Queue * | response_queue | ) |
Set stream flags if needed based on the type of the frame that was just sent (e.g., close stream if it was RST_STREAM).
response_queue | sent for this stream |
Definition at line 126 of file stream.c.
References SPDYF_Response_Queue::control_frame, SPDYF_Response_Queue::data_frame, SPDYF_Stream::is_in_closed, SPDYF_Stream::is_out_closed, NULL, SPDY_CONTROL_FRAME_TYPES_RST_STREAM, SPDY_CONTROL_FRAME_TYPES_SYN_REPLY, SPDY_DATA_FLAG_FIN, SPDY_SYN_REPLY_FLAG_FIN, and SPDYF_Response_Queue::stream.
Referenced by SPDYF_session_write().