mirror of
https://github.com/cuberite/libevent.git
synced 2025-09-10 13:04:23 -04:00
Clean up formatting: remove trailing spaces
This commit is contained in:
parent
e5bbd40ad7
commit
e5cf98795e
@ -83,7 +83,7 @@ struct { \
|
|||||||
SPLAY_RIGHT(tmp, field) = (head)->sph_root; \
|
SPLAY_RIGHT(tmp, field) = (head)->sph_root; \
|
||||||
(head)->sph_root = tmp; \
|
(head)->sph_root = tmp; \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
#define SPLAY_ROTATE_LEFT(head, tmp, field) do { \
|
#define SPLAY_ROTATE_LEFT(head, tmp, field) do { \
|
||||||
SPLAY_RIGHT((head)->sph_root, field) = SPLAY_LEFT(tmp, field); \
|
SPLAY_RIGHT((head)->sph_root, field) = SPLAY_LEFT(tmp, field); \
|
||||||
SPLAY_LEFT(tmp, field) = (head)->sph_root; \
|
SPLAY_LEFT(tmp, field) = (head)->sph_root; \
|
||||||
@ -760,7 +760,7 @@ struct { \
|
|||||||
SPLAY_RIGHT(tmp, field) = (head)->sph_root; \
|
SPLAY_RIGHT(tmp, field) = (head)->sph_root; \
|
||||||
(head)->sph_root = tmp; \
|
(head)->sph_root = tmp; \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
#define SPLAY_ROTATE_LEFT(head, tmp, field) do { \
|
#define SPLAY_ROTATE_LEFT(head, tmp, field) do { \
|
||||||
SPLAY_RIGHT((head)->sph_root, field) = SPLAY_LEFT(tmp, field); \
|
SPLAY_RIGHT((head)->sph_root, field) = SPLAY_LEFT(tmp, field); \
|
||||||
SPLAY_LEFT(tmp, field) = (head)->sph_root; \
|
SPLAY_LEFT(tmp, field) = (head)->sph_root; \
|
||||||
|
@ -203,7 +203,7 @@ be_async_outbuf_callback(struct evbuffer *buf,
|
|||||||
struct bufferevent *bev = arg;
|
struct bufferevent *bev = arg;
|
||||||
struct bufferevent_async *bev_async = upcast(bev);
|
struct bufferevent_async *bev_async = upcast(bev);
|
||||||
|
|
||||||
/* If we added data to the outbuf and were not writing before,
|
/* If we added data to the outbuf and were not writing before,
|
||||||
* we may want to write now. */
|
* we may want to write now. */
|
||||||
|
|
||||||
_bufferevent_incref_and_lock(bev);
|
_bufferevent_incref_and_lock(bev);
|
||||||
|
@ -36,7 +36,7 @@
|
|||||||
#define _SYS_QUEUE_H_
|
#define _SYS_QUEUE_H_
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* This file defines five types of data structures: singly-linked lists,
|
* This file defines five types of data structures: singly-linked lists,
|
||||||
* lists, simple queues, tail queues, and circular queues.
|
* lists, simple queues, tail queues, and circular queues.
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
@ -89,7 +89,7 @@
|
|||||||
struct name { \
|
struct name { \
|
||||||
struct type *slh_first; /* first element */ \
|
struct type *slh_first; /* first element */ \
|
||||||
}
|
}
|
||||||
|
|
||||||
#define SLIST_HEAD_INITIALIZER(head) \
|
#define SLIST_HEAD_INITIALIZER(head) \
|
||||||
{ NULL }
|
{ NULL }
|
||||||
|
|
||||||
@ -287,8 +287,8 @@ struct { \
|
|||||||
struct type **tqe_prev; /* address of previous next element */ \
|
struct type **tqe_prev; /* address of previous next element */ \
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* tail queue access methods
|
* tail queue access methods
|
||||||
*/
|
*/
|
||||||
#define TAILQ_FIRST(head) ((head)->tqh_first)
|
#define TAILQ_FIRST(head) ((head)->tqh_first)
|
||||||
#define TAILQ_END(head) NULL
|
#define TAILQ_END(head) NULL
|
||||||
@ -391,7 +391,7 @@ struct { \
|
|||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Circular queue access methods
|
* Circular queue access methods
|
||||||
*/
|
*/
|
||||||
#define CIRCLEQ_FIRST(head) ((head)->cqh_first)
|
#define CIRCLEQ_FIRST(head) ((head)->cqh_first)
|
||||||
#define CIRCLEQ_LAST(head) ((head)->cqh_last)
|
#define CIRCLEQ_LAST(head) ((head)->cqh_last)
|
||||||
|
2
event.c
2
event.c
@ -878,7 +878,7 @@ event_base_priority_init(struct event_base *base, int npriorities)
|
|||||||
return (-1);
|
return (-1);
|
||||||
}
|
}
|
||||||
base->nactivequeues = npriorities;
|
base->nactivequeues = npriorities;
|
||||||
|
|
||||||
for (i = 0; i < base->nactivequeues; ++i) {
|
for (i = 0; i < base->nactivequeues; ++i) {
|
||||||
TAILQ_INIT(&base->activequeues[i]);
|
TAILQ_INIT(&base->activequeues[i]);
|
||||||
}
|
}
|
||||||
|
2
http.c
2
http.c
@ -1434,7 +1434,7 @@ evhttp_add_header(struct evkeyvalq *headers,
|
|||||||
event_debug(("%s: dropping illegal header key\n", __func__));
|
event_debug(("%s: dropping illegal header key\n", __func__));
|
||||||
return (-1);
|
return (-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!evhttp_header_is_valid_value(value)) {
|
if (!evhttp_header_is_valid_value(value)) {
|
||||||
event_debug(("%s: dropping illegal header value\n", __func__));
|
event_debug(("%s: dropping illegal header value\n", __func__));
|
||||||
return (-1);
|
return (-1);
|
||||||
|
@ -232,7 +232,7 @@ int evutil_make_listen_socket_reuseable(evutil_socket_t sock);
|
|||||||
|
|
||||||
/** Do platform-specific operations as needed to close a socket upon a
|
/** Do platform-specific operations as needed to close a socket upon a
|
||||||
successful execution of one of the exec*() functions.
|
successful execution of one of the exec*() functions.
|
||||||
|
|
||||||
@param sock The socket to be closed
|
@param sock The socket to be closed
|
||||||
@return 0 on success, -1 on failure
|
@return 0 on success, -1 on failure
|
||||||
*/
|
*/
|
||||||
|
@ -124,7 +124,7 @@ void _evbuffer_overlapped_set_fd(struct evbuffer *buf, evutil_socket_t fd);
|
|||||||
An evbuffer can only have one read pending at a time. While the read
|
An evbuffer can only have one read pending at a time. While the read
|
||||||
is in progress, no other data may be added to the end of the buffer.
|
is in progress, no other data may be added to the end of the buffer.
|
||||||
The buffer must be created with event_overlapped_init().
|
The buffer must be created with event_overlapped_init().
|
||||||
evbuffer_commit_read() must be called in the completion callback.
|
evbuffer_commit_read() must be called in the completion callback.
|
||||||
|
|
||||||
@param buf The buffer to read onto
|
@param buf The buffer to read onto
|
||||||
@param n The number of bytes to try to read.
|
@param n The number of bytes to try to read.
|
||||||
@ -138,7 +138,7 @@ int evbuffer_launch_read(struct evbuffer *buf, size_t n, struct event_overlapped
|
|||||||
An evbuffer can only have one write pending at a time. While the write is
|
An evbuffer can only have one write pending at a time. While the write is
|
||||||
in progress, no other data may be removed from the front of the buffer.
|
in progress, no other data may be removed from the front of the buffer.
|
||||||
The buffer must be created with event_overlapped_init().
|
The buffer must be created with event_overlapped_init().
|
||||||
evbuffer_commit_write() must be called in the completion callback.
|
evbuffer_commit_write() must be called in the completion callback.
|
||||||
|
|
||||||
@param buf The buffer to read onto
|
@param buf The buffer to read onto
|
||||||
@param n The number of bytes to try to read.
|
@param n The number of bytes to try to read.
|
||||||
|
@ -194,7 +194,7 @@ evconnlistener_new_bind(struct event_base *base, evconnlistener_cb cb,
|
|||||||
listener = evconnlistener_new(base, cb, ptr, flags, backlog, fd);
|
listener = evconnlistener_new(base, cb, ptr, flags, backlog, fd);
|
||||||
if (!listener) {
|
if (!listener) {
|
||||||
EVUTIL_CLOSESOCKET(fd);
|
EVUTIL_CLOSESOCKET(fd);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
return listener;
|
return listener;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user