MCPcopy Create free account
hub / github.com/apache/httpd / h2_stream_submit_pushes

Function h2_stream_submit_pushes

modules/http2/h2_stream.c:1225–1250  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1223
1224#if AP_HAS_RESPONSE_BUCKETS
1225apr_status_t h2_stream_submit_pushes(h2_stream *stream, ap_bucket_response *response)
1226#else
1227apr_status_t h2_stream_submit_pushes(h2_stream *stream, h2_headers *response)
1228#endif
1229{
1230 apr_status_t status = APR_SUCCESS;
1231 apr_array_header_t *pushes;
1232 int i;
1233
1234 H2_STRM_ASSERT_MAGIC(stream, H2_STRM_MAGIC_OK);
1235 pushes = h2_push_collect_update(stream, stream->request, response);
1236 if (pushes && !apr_is_empty_array(pushes)) {
1237 ap_log_cerror(APLOG_MARK, APLOG_TRACE1, 0, stream->session->c1,
1238 H2_STRM_MSG(stream, "found %d push candidates"),
1239 pushes->nelts);
1240 for (i = 0; i < pushes->nelts; ++i) {
1241 h2_push *push = APR_ARRAY_IDX(pushes, i, h2_push*);
1242 h2_stream *s = h2_session_push(stream->session, stream, push);
1243 if (!s) {
1244 status = APR_ECONNRESET;
1245 break;
1246 }
1247 }
1248 }
1249 return status;
1250}
1251
1252apr_table_t *h2_stream_get_trailers(h2_stream *stream)
1253{

Callers 1

h2_stream.cFile · 0.85

Calls 2

h2_push_collect_updateFunction · 0.85
h2_session_pushFunction · 0.85

Tested by

no test coverage detected