I just started using this last night, but am encountering a seg fault when I call apreq_body() in an InputFilter (C-based) during an HTTP POST. I am able to call this (returns non APR_SUCCESS) when the method is GET, but crashes when I switch to POST. I am able to call apreq_params() and determine the number of input parameters, so I am thinking that I am violating a fundamental operational principal.
apreq_handle_t* h = apreq_handle_apache2(r); const apr_table_t* form_table = NULL; if (apreq_body(h, &form_table) != APR_SUCCESS) --> seg fault I plan on looking into this deeper in a few hours, but am wondering if the symptoms are revealing enough that someone can give some guidance. Also, does this filter consume the form data, leave it for other filters etc to process, or is this configurable? I am writing two input filters, one that passively sniffs data and another that performs local redirects. Only my filters are guarenteed to be using apreq... Thanks, Erik