diff options
author | Vladimír Čunát <vladimir.cunat@nic.cz> | 2020-08-10 16:51:27 +0200 |
---|---|---|
committer | Vladimír Čunát <vladimir.cunat@nic.cz> | 2020-08-27 10:07:31 +0200 |
commit | 08798e5cefd2bf1dfa3e07dc86a35c9099a901d0 (patch) | |
tree | 26225bbcc1f15c521b988557a64bdfba94e19960 | |
parent | lib/generic/queue: fix a bug (diff) | |
download | knot-resolver-08798e5cefd2bf1dfa3e07dc86a35c9099a901d0.tar.xz knot-resolver-08798e5cefd2bf1dfa3e07dc86a35c9099a901d0.zip |
lib/generic/queue: move KR_EXPORT to header
It... feels better that way.
-rw-r--r-- | lib/generic/queue.c | 8 | ||||
-rw-r--r-- | lib/generic/queue.h | 8 |
2 files changed, 8 insertions, 8 deletions
diff --git a/lib/generic/queue.c b/lib/generic/queue.c index afe8c6eb..f46050ff 100644 --- a/lib/generic/queue.c +++ b/lib/generic/queue.c @@ -5,7 +5,7 @@ #include "lib/generic/queue.h" #include <string.h> -KR_EXPORT void queue_init_impl(struct queue *q, size_t item_size) +void queue_init_impl(struct queue *q, size_t item_size) { q->len = 0; q->item_size = item_size; @@ -19,7 +19,7 @@ KR_EXPORT void queue_init_impl(struct queue *q, size_t item_size) if (!q->chunk_cap) q->chunk_cap = 1; /* item_size big enough by itself */ } -KR_EXPORT void queue_deinit_impl(struct queue *q) +void queue_deinit_impl(struct queue *q) { assert(q); struct queue_chunk *p = q->head; @@ -46,7 +46,7 @@ static struct queue_chunk * queue_chunk_new(const struct queue *q) } /* Return pointer to the space for the new element. */ -KR_EXPORT void * queue_push_impl(struct queue *q) +void * queue_push_impl(struct queue *q) { assert(q); struct queue_chunk *t = q->tail; // shorthand @@ -75,7 +75,7 @@ KR_EXPORT void * queue_push_impl(struct queue *q) } /* Return pointer to the space for the new element. */ -KR_EXPORT void * queue_push_head_impl(struct queue *q) +void * queue_push_head_impl(struct queue *q) { /* When we have choice, we optimize for further _push_head, * i.e. when shifting or allocating a chunk, diff --git a/lib/generic/queue.h b/lib/generic/queue.h index e538b81a..75c2a835 100644 --- a/lib/generic/queue.h +++ b/lib/generic/queue.h @@ -142,10 +142,10 @@ struct queue; /* Non-inline functions are exported to be usable from daemon. */ -void queue_init_impl(struct queue *q, size_t item_size); -void queue_deinit_impl(struct queue *q); -void * queue_push_impl(struct queue *q); -void * queue_push_head_impl(struct queue *q); +KR_EXPORT void queue_init_impl(struct queue *q, size_t item_size); +KR_EXPORT void queue_deinit_impl(struct queue *q); +KR_EXPORT void * queue_push_impl(struct queue *q); +KR_EXPORT void * queue_push_head_impl(struct queue *q); struct queue_chunk; struct queue { |