summaryrefslogtreecommitdiff
path: root/buckets
diff options
context:
space:
mode:
authorIvan Zhakov <ivan@apache.org>2022-11-20 07:14:38 +0000
committerIvan Zhakov <ivan@apache.org>2022-11-20 07:14:38 +0000
commit4f9b76b6f2acc4030ce9ef164322514c5d0e761b (patch)
tree9b993b3753affcbf164056826f9d568d8760b3a1 /buckets
parent961caf5f46055483fa72ab02f5e8baa16c209e2f (diff)
downloadapr-4f9b76b6f2acc4030ce9ef164322514c5d0e761b.tar.gz
Remove trailing whitespaces in *.c.
git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@1905414 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'buckets')
-rw-r--r--buckets/apr_brigade.c44
-rw-r--r--buckets/apr_buckets_eos.c4
-rw-r--r--buckets/apr_buckets_flush.c6
-rw-r--r--buckets/apr_buckets_heap.c2
-rw-r--r--buckets/apr_buckets_mmap.c12
-rw-r--r--buckets/apr_buckets_pipe.c6
-rw-r--r--buckets/apr_buckets_pool.c2
-rw-r--r--buckets/apr_buckets_simple.c4
-rw-r--r--buckets/apr_buckets_socket.c6
9 files changed, 43 insertions, 43 deletions
diff --git a/buckets/apr_brigade.c b/buckets/apr_brigade.c
index 20c7d192c..5a9403163 100644
--- a/buckets/apr_brigade.c
+++ b/buckets/apr_brigade.c
@@ -29,7 +29,7 @@
#include <sys/uio.h>
#endif
-static apr_status_t brigade_cleanup(void *data)
+static apr_status_t brigade_cleanup(void *data)
{
return apr_brigade_cleanup(data);
}
@@ -57,7 +57,7 @@ APR_DECLARE(apr_status_t) apr_brigade_cleanup(void *data)
apr_bucket_delete(e);
}
#endif
-
+
/* We don't need to free(bb) because it's allocated from a pool. */
return APR_SUCCESS;
}
@@ -68,7 +68,7 @@ APR_DECLARE(apr_status_t) apr_brigade_destroy(apr_bucket_brigade *b)
return apr_pool_cleanup_run(b->p, b, brigade_cleanup);
#else
apr_status_t rv;
-
+
APR_BRIGADE_CHECK_CONSISTENCY(b);
rv = apr_pool_cleanup_run(b->p, b, brigade_cleanup);
@@ -109,8 +109,8 @@ APR_DECLARE(apr_bucket_brigade *) apr_brigade_split_ex(apr_bucket_brigade *b,
else if (!APR_BRIGADE_EMPTY(a)) {
apr_brigade_cleanup(a);
}
- /* Return an empty brigade if there is nothing left in
- * the first brigade to split off
+ /* Return an empty brigade if there is nothing left in
+ * the first brigade to split off
*/
if (e != APR_BRIGADE_SENTINEL(b)) {
f = APR_RING_LAST(&b->list);
@@ -183,7 +183,7 @@ APR_DECLARE(apr_status_t) apr_brigade_partition(apr_bucket_brigade *b,
* and is within this bucket, or this bucket's len
* is undefined, so now we are ready to split it.
* First try to split the bucket natively... */
- if ((rv = apr_bucket_split(e, (apr_size_t)point64))
+ if ((rv = apr_bucket_split(e, (apr_size_t)point64))
!= APR_ENOTIMPL) {
*after_point = APR_BUCKET_NEXT(e);
return rv;
@@ -212,7 +212,7 @@ APR_DECLARE(apr_status_t) apr_brigade_partition(apr_bucket_brigade *b,
}
point64 -= (apr_uint64_t)e->length;
}
- *after_point = APR_BRIGADE_SENTINEL(b);
+ *after_point = APR_BRIGADE_SENTINEL(b);
return APR_INCOMPLETE;
}
@@ -254,7 +254,7 @@ APR_DECLARE(apr_status_t) apr_brigade_flatten(apr_bucket_brigade *bb,
{
apr_size_t actual = 0;
apr_bucket *b;
-
+
for (b = APR_BRIGADE_FIRST(bb);
b != APR_BRIGADE_SENTINEL(bb);
b = APR_BUCKET_NEXT(b))
@@ -304,14 +304,14 @@ APR_DECLARE(apr_status_t) apr_brigade_pflatten(apr_bucket_brigade *bb,
apr_status_t rv;
apr_brigade_length(bb, 1, &actual);
-
+
/* XXX: This is dangerous beyond belief. At least in the
* apr_brigade_flatten case, the user explicitly stated their
* buffer length - so we don't up and palloc 4GB for a single
* file bucket. This API must grow a useful max boundry,
* either compiled-in or preset via the *len value.
*
- * Shouldn't both fn's grow an additional return value for
+ * Shouldn't both fn's grow an additional return value for
* the case that the brigade couldn't be flattened into the
* provided or allocated buffer (such as APR_EMOREDATA?)
* Not a failure, simply an advisory result.
@@ -319,7 +319,7 @@ APR_DECLARE(apr_status_t) apr_brigade_pflatten(apr_bucket_brigade *bb,
total = (apr_size_t)actual;
*c = apr_palloc(pool, total);
-
+
rv = apr_brigade_flatten(bb, *c, &total);
if (rv != APR_SUCCESS) {
@@ -687,7 +687,7 @@ skip:
}
-APR_DECLARE(apr_status_t) apr_brigade_to_iovec(apr_bucket_brigade *b,
+APR_DECLARE(apr_status_t) apr_brigade_to_iovec(apr_bucket_brigade *b,
struct iovec *vec, int *nvec)
{
int left = *nvec;
@@ -719,7 +719,7 @@ APR_DECLARE(apr_status_t) apr_brigade_to_iovec(apr_bucket_brigade *b,
return APR_SUCCESS;
}
-APR_DECLARE(apr_status_t) apr_brigade_vputstrs(apr_bucket_brigade *b,
+APR_DECLARE(apr_status_t) apr_brigade_vputstrs(apr_bucket_brigade *b,
apr_brigade_flush flush,
void *ctx,
va_list va)
@@ -761,7 +761,7 @@ APR_DECLARE(apr_status_t) apr_brigade_putc(apr_bucket_brigade *b,
APR_DECLARE(apr_status_t) apr_brigade_write(apr_bucket_brigade *b,
apr_brigade_flush flush,
- void *ctx,
+ void *ctx,
const char *str, apr_size_t nbyte)
{
apr_bucket *e = APR_BRIGADE_LAST(b);
@@ -782,7 +782,7 @@ APR_DECLARE(apr_status_t) apr_brigade_write(apr_bucket_brigade *b,
}
if (nbyte > remaining) {
- /* either a buffer bucket exists but is full,
+ /* either a buffer bucket exists but is full,
* or no buffer bucket exists and the data is too big
* to buffer. In either case, we should flush. */
if (flush) {
@@ -946,7 +946,7 @@ APR_DECLARE(apr_status_t) apr_brigade_puts(apr_bucket_brigade *bb,
return apr_brigade_write(bb, flush, ctx, str, strlen(str));
}
-APR_DECLARE_NONSTD(apr_status_t) apr_brigade_putstrs(apr_bucket_brigade *b,
+APR_DECLARE_NONSTD(apr_status_t) apr_brigade_putstrs(apr_bucket_brigade *b,
apr_brigade_flush flush,
void *ctx, ...)
{
@@ -959,9 +959,9 @@ APR_DECLARE_NONSTD(apr_status_t) apr_brigade_putstrs(apr_bucket_brigade *b,
return rv;
}
-APR_DECLARE_NONSTD(apr_status_t) apr_brigade_printf(apr_bucket_brigade *b,
+APR_DECLARE_NONSTD(apr_status_t) apr_brigade_printf(apr_bucket_brigade *b,
apr_brigade_flush flush,
- void *ctx,
+ void *ctx,
const char *fmt, ...)
{
va_list ap;
@@ -1046,12 +1046,12 @@ APR_DECLARE(apr_bucket *) apr_brigade_insert_file(apr_bucket_brigade *bb,
apr_bucket *e;
if (sizeof(apr_off_t) == sizeof(apr_size_t) || length < MAX_BUCKET_SIZE) {
- e = apr_bucket_file_create(f, start, (apr_size_t)length, p,
+ e = apr_bucket_file_create(f, start, (apr_size_t)length, p,
bb->bucket_alloc);
}
else {
- /* Several buckets are needed. */
- e = apr_bucket_file_create(f, start, MAX_BUCKET_SIZE, p,
+ /* Several buckets are needed. */
+ e = apr_bucket_file_create(f, start, MAX_BUCKET_SIZE, p,
bb->bucket_alloc);
while (length > MAX_BUCKET_SIZE) {
@@ -1063,7 +1063,7 @@ APR_DECLARE(apr_bucket *) apr_brigade_insert_file(apr_bucket_brigade *bb,
}
e->length = (apr_size_t)length; /* Resize just the last bucket */
}
-
+
APR_BRIGADE_INSERT_TAIL(bb, e);
return e;
}
diff --git a/buckets/apr_buckets_eos.c b/buckets/apr_buckets_eos.c
index 446cd3c23..561cab6dd 100644
--- a/buckets/apr_buckets_eos.c
+++ b/buckets/apr_buckets_eos.c
@@ -16,7 +16,7 @@
#include "apr_buckets.h"
-static apr_status_t eos_bucket_read(apr_bucket *b, const char **str,
+static apr_status_t eos_bucket_read(apr_bucket *b, const char **str,
apr_size_t *len, apr_read_type_e block)
{
*str = NULL;
@@ -30,7 +30,7 @@ APR_DECLARE(apr_bucket *) apr_bucket_eos_make(apr_bucket *b)
b->start = 0;
b->data = NULL;
b->type = &apr_bucket_type_eos;
-
+
return b;
}
diff --git a/buckets/apr_buckets_flush.c b/buckets/apr_buckets_flush.c
index dbb4fb9ba..0d5645acf 100644
--- a/buckets/apr_buckets_flush.c
+++ b/buckets/apr_buckets_flush.c
@@ -16,7 +16,7 @@
#include "apr_buckets.h"
-static apr_status_t flush_bucket_read(apr_bucket *b, const char **str,
+static apr_status_t flush_bucket_read(apr_bucket *b, const char **str,
apr_size_t *len, apr_read_type_e block)
{
*str = NULL;
@@ -30,7 +30,7 @@ APR_DECLARE(apr_bucket *) apr_bucket_flush_make(apr_bucket *b)
b->start = 0;
b->data = NULL;
b->type = &apr_bucket_type_flush;
-
+
return b;
}
@@ -45,7 +45,7 @@ APR_DECLARE(apr_bucket *) apr_bucket_flush_create(apr_bucket_alloc_t *list)
}
APR_DECLARE_DATA const apr_bucket_type_t apr_bucket_type_flush = {
- "FLUSH", 5, APR_BUCKET_METADATA,
+ "FLUSH", 5, APR_BUCKET_METADATA,
apr_bucket_destroy_noop,
flush_bucket_read,
apr_bucket_setaside_noop,
diff --git a/buckets/apr_buckets_heap.c b/buckets/apr_buckets_heap.c
index 7405d2caf..81e0cfac0 100644
--- a/buckets/apr_buckets_heap.c
+++ b/buckets/apr_buckets_heap.c
@@ -18,7 +18,7 @@
#define APR_WANT_MEMFUNC
#include "apr_want.h"
-static apr_status_t heap_bucket_read(apr_bucket *b, const char **str,
+static apr_status_t heap_bucket_read(apr_bucket *b, const char **str,
apr_size_t *len, apr_read_type_e block)
{
apr_bucket_heap *h = b->data;
diff --git a/buckets/apr_buckets_mmap.c b/buckets/apr_buckets_mmap.c
index 116b78868..9a111a797 100644
--- a/buckets/apr_buckets_mmap.c
+++ b/buckets/apr_buckets_mmap.c
@@ -18,13 +18,13 @@
#if APR_HAS_MMAP
-static apr_status_t mmap_bucket_read(apr_bucket *b, const char **str,
+static apr_status_t mmap_bucket_read(apr_bucket *b, const char **str,
apr_size_t *length, apr_read_type_e block)
{
apr_bucket_mmap *m = b->data;
apr_status_t ok;
void *addr;
-
+
if (!m->mmap) {
/* the apr_mmap_t was already cleaned up out from under us */
return APR_EINVAL;
@@ -68,8 +68,8 @@ static void mmap_bucket_destroy(void *data)
/*
* XXX: are the start and length arguments useful?
*/
-APR_DECLARE(apr_bucket *) apr_bucket_mmap_make(apr_bucket *b, apr_mmap_t *mm,
- apr_off_t start,
+APR_DECLARE(apr_bucket *) apr_bucket_mmap_make(apr_bucket *b, apr_mmap_t *mm,
+ apr_off_t start,
apr_size_t length)
{
apr_bucket_mmap *m;
@@ -87,8 +87,8 @@ APR_DECLARE(apr_bucket *) apr_bucket_mmap_make(apr_bucket *b, apr_mmap_t *mm,
}
-APR_DECLARE(apr_bucket *) apr_bucket_mmap_create(apr_mmap_t *mm,
- apr_off_t start,
+APR_DECLARE(apr_bucket *) apr_bucket_mmap_create(apr_mmap_t *mm,
+ apr_off_t start,
apr_size_t length,
apr_bucket_alloc_t *list)
{
diff --git a/buckets/apr_buckets_pipe.c b/buckets/apr_buckets_pipe.c
index 574610b02..4c4730156 100644
--- a/buckets/apr_buckets_pipe.c
+++ b/buckets/apr_buckets_pipe.c
@@ -46,7 +46,7 @@ static apr_status_t pipe_bucket_read(apr_bucket *a, const char **str,
/*
* If there's more to read we have to keep the rest of the pipe
* for later. Otherwise, we'll close the pipe.
- * XXX: Note that more complicated bucket types that
+ * XXX: Note that more complicated bucket types that
* refer to data not in memory and must therefore have a read()
* function similar to this one should be wary of copying this
* code because if they have a destroy function they probably
@@ -94,7 +94,7 @@ APR_DECLARE(apr_bucket *) apr_bucket_pipe_make(apr_bucket *b, apr_file_t *p)
b->length = (apr_size_t)(-1);
b->start = -1;
b->data = p;
-
+
return b;
}
@@ -110,7 +110,7 @@ APR_DECLARE(apr_bucket *) apr_bucket_pipe_create(apr_file_t *p,
}
APR_DECLARE_DATA const apr_bucket_type_t apr_bucket_type_pipe = {
- "PIPE", 5, APR_BUCKET_DATA,
+ "PIPE", 5, APR_BUCKET_DATA,
apr_bucket_destroy_noop,
pipe_bucket_read,
apr_bucket_setaside_notimpl,
diff --git a/buckets/apr_buckets_pool.c b/buckets/apr_buckets_pool.c
index da6029072..2d68da593 100644
--- a/buckets/apr_buckets_pool.c
+++ b/buckets/apr_buckets_pool.c
@@ -42,7 +42,7 @@ static apr_status_t pool_bucket_cleanup(void *data)
return APR_SUCCESS;
}
-static apr_status_t pool_bucket_read(apr_bucket *b, const char **str,
+static apr_status_t pool_bucket_read(apr_bucket *b, const char **str,
apr_size_t *len, apr_read_type_e block)
{
apr_bucket_pool *p = b->data;
diff --git a/buckets/apr_buckets_simple.c b/buckets/apr_buckets_simple.c
index 14f11ba7d..fbe79810e 100644
--- a/buckets/apr_buckets_simple.c
+++ b/buckets/apr_buckets_simple.c
@@ -45,7 +45,7 @@ APR_DECLARE_NONSTD(apr_status_t) apr_bucket_simple_split(apr_bucket *a,
return APR_SUCCESS;
}
-static apr_status_t simple_bucket_read(apr_bucket *b, const char **str,
+static apr_status_t simple_bucket_read(apr_bucket *b, const char **str,
apr_size_t *len, apr_read_type_e block)
{
*str = (char *)b->data + b->start;
@@ -129,7 +129,7 @@ const apr_bucket_type_t apr_bucket_type_immortal = {
APR_DECLARE_DATA const apr_bucket_type_t apr_bucket_type_transient = {
"TRANSIENT", 5, APR_BUCKET_DATA,
- apr_bucket_destroy_noop,
+ apr_bucket_destroy_noop,
simple_bucket_read,
transient_bucket_setaside,
apr_bucket_simple_split,
diff --git a/buckets/apr_buckets_socket.c b/buckets/apr_buckets_socket.c
index 556304962..2a1ca9e1f 100644
--- a/buckets/apr_buckets_socket.c
+++ b/buckets/apr_buckets_socket.c
@@ -55,7 +55,7 @@ static apr_status_t socket_bucket_read(apr_bucket *a, const char **str,
* new bucket.
*
* Even if there is nothing more to read, don't close the socket here
- * as we have to use it to send any response :) We could shut it
+ * as we have to use it to send any response :) We could shut it
* down for reading, but there is no benefit to doing so.
*/
if (*len > 0) {
@@ -83,7 +83,7 @@ APR_DECLARE(apr_bucket *) apr_bucket_socket_make(apr_bucket *b, apr_socket_t *p)
* destroy it instead.
*
* Note that typically the socket is allocated from the connection pool
- * so it will disappear when the connection is finished.
+ * so it will disappear when the connection is finished.
*/
b->type = &apr_bucket_type_socket;
b->length = (apr_size_t)(-1);
@@ -108,7 +108,7 @@ APR_DECLARE_DATA const apr_bucket_type_t apr_bucket_type_socket = {
"SOCKET", 5, APR_BUCKET_DATA,
apr_bucket_destroy_noop,
socket_bucket_read,
- apr_bucket_setaside_notimpl,
+ apr_bucket_setaside_notimpl,
apr_bucket_split_notimpl,
apr_bucket_copy_notimpl
};