*/
AP_DECLARE(const char *) ap_method_name_of(int methnum);
-apr_status_t http_filter(ap_filter_t *f, ap_bucket_brigade *b, ap_input_mode_t mode);
-apr_status_t dechunk_filter(ap_filter_t *f, ap_bucket_brigade *b, ap_input_mode_t mode);
+apr_status_t ap_http_filter(ap_filter_t *f, ap_bucket_brigade *b, ap_input_mode_t mode);
+apr_status_t ap_dechunk_filter(ap_filter_t *f, ap_bucket_brigade *b, ap_input_mode_t mode);
/* Hooks */
/*
* filters
*/
ap_hook_insert_filter(core_insert_filter, NULL, NULL, AP_HOOK_MIDDLE);
- ap_register_input_filter("HTTP_IN", http_filter, AP_FTYPE_CONNECTION);
- ap_register_input_filter("DECHUNK", dechunk_filter, AP_FTYPE_CONNECTION + 1);
+ ap_register_input_filter("HTTP_IN", ap_http_filter, AP_FTYPE_CONNECTION);
+ ap_register_input_filter("DECHUNK", ap_dechunk_filter, AP_FTYPE_CONNECTION + 1);
ap_register_input_filter("CORE_IN", core_input_filter, AP_FTYPE_CONNECTION);
ap_register_output_filter("HTTP_HEADER", ap_http_header_filter, AP_FTYPE_CONTENT + 1);
ap_register_output_filter("CORE", core_output_filter, AP_FTYPE_CONNECTION + 1);
static long get_chunk_size(char *);
static int getline(char *s, int n, request_rec *r, int fold);
-apr_status_t dechunk_filter(ap_filter_t *f, ap_bucket_brigade *bb,
- ap_input_mode_t mode)
+apr_status_t ap_dechunk_filter(ap_filter_t *f, ap_bucket_brigade *bb,
+ ap_input_mode_t mode)
{
apr_status_t rv;
struct dechunk_ctx *ctx = f->ctx;
do {
if (ctx->chunk_size == ctx->bytes_delivered) {
- /* Time to read another chunk header or trailer... http_filter() is
+ /* Time to read another chunk header or trailer... ap_http_filter() is
* the next filter in line and it knows how to return a brigade with
* one line.
*/
} while (ctx->state != WANT_BODY);
if (ctx->state == WANT_BODY) {
- /* Tell http_filter() how many bytes to deliver. */
+ /* Tell ap_http_filter() how many bytes to deliver. */
f->c->remain = ctx->chunk_size - ctx->bytes_delivered;
if ((rv = ap_get_brigade(f->next, bb, mode)) != APR_SUCCESS) {
return rv;
}
/* Walk through the body, accounting for bytes, and removing an eos bucket if
- * http_filter() delivered the entire chunk.
+ * ap_http_filter() delivered the entire chunk.
*/
b = AP_BRIGADE_FIRST(bb);
while (b != AP_BRIGADE_SENTINEL(bb) && !AP_BUCKET_IS_EOS(b)) {
ap_bucket_brigade *b;
} http_ctx_t;
-apr_status_t http_filter(ap_filter_t *f, ap_bucket_brigade *b, ap_input_mode_t mode)
+apr_status_t ap_http_filter(ap_filter_t *f, ap_bucket_brigade *b, ap_input_mode_t mode)
{
#define ASCII_LF '\012'
ap_bucket *e;