1399
1399
* can simply insert our buffered data at the front and
1400
1400
* pass the whole bundle down the chain.
1402
APR_BRIGADE_CONCAT(ctx->bb, bb);
1402
APR_BRIGADE_PREPEND(bb, ctx->bb);
1407
1405
return ap_pass_brigade(f->next, bb);
1540
1538
written = apr_vformatter(r_flush, &vd.vbuff, fmt, va);
1542
/* tack on null terminator on remaining string */
1543
*(vd.vbuff.curpos) = '\0';
1545
1540
if (written != -1) {
1546
1541
int n = vd.vbuff.curpos - vrprintf_buf;
1631
typedef struct hdr_ptr {
1633
apr_bucket_brigade *bb;
1636
static int send_header(void *data, const char *key, const char *val)
1638
ap_fputstrs(((hdr_ptr*)data)->f, ((hdr_ptr*)data)->bb,
1639
key, ": ", val, CRLF, NULL);
1643
AP_DECLARE(void) ap_send_interim_response(request_rec *r, int send_headers)
1647
if (r->proto_num < 1001) {
1648
/* don't send interim response to HTTP/1.0 Client */
1651
if (!ap_is_HTTP_INFO(r->status)) {
1652
ap_log_rerror(APLOG_MARK, APLOG_DEBUG, 0, NULL,
1653
"Status is %d - not sending interim response", r->status);
1657
x.f = r->connection->output_filters;
1658
x.bb = apr_brigade_create(r->pool, r->connection->bucket_alloc);
1659
ap_fputstrs(x.f, x.bb, AP_SERVER_PROTOCOL, " ", r->status_line, CRLF, NULL);
1661
apr_table_do(send_header, &x, r->headers_out, NULL);
1662
apr_table_clear(r->headers_out);
1664
ap_fputs(x.f, x.bb, CRLF);
1665
ap_fflush(x.f, x.bb);
1666
apr_brigade_destroy(x.bb);
1636
1669
AP_IMPLEMENT_HOOK_RUN_ALL(int,post_read_request,
1637
1670
(request_rec *r), (r), OK, DECLINED)
1638
1671
AP_IMPLEMENT_HOOK_RUN_ALL(int,log_transaction,