| 2218 | } |
| 2219 | |
| 2220 | AP_DECLARE_NONSTD(int) ap_rvputs(request_rec *r, ...) |
| 2221 | { |
| 2222 | va_list va; |
| 2223 | const char *s; |
| 2224 | apr_size_t len; |
| 2225 | apr_size_t written = 0; |
| 2226 | |
| 2227 | if (r->connection->aborted) |
| 2228 | return -1; |
| 2229 | |
| 2230 | /* ### TODO: if the total output is large, put all the strings |
| 2231 | * ### into a single brigade, rather than flushing each time we |
| 2232 | * ### fill the buffer |
| 2233 | */ |
| 2234 | va_start(va, r); |
| 2235 | while (1) { |
| 2236 | s = va_arg(va, const char *); |
| 2237 | if (s == NULL) |
| 2238 | break; |
| 2239 | |
| 2240 | len = strlen(s); |
| 2241 | if (buffer_output(r, s, len) != APR_SUCCESS) { |
| 2242 | va_end(va); |
| 2243 | return -1; |
| 2244 | } |
| 2245 | |
| 2246 | written += len; |
| 2247 | } |
| 2248 | va_end(va); |
| 2249 | |
| 2250 | return written; |
| 2251 | } |
| 2252 | |
| 2253 | AP_DECLARE(int) ap_rflush(request_rec *r) |
| 2254 | { |
no test coverage detected