From acc34e2d51beda13e5bc4c5047b54cbedd5b5ac0 Mon Sep 17 00:00:00 2001 From: Joris Vink Date: Thu, 22 Aug 2013 10:06:39 +0200 Subject: [PATCH] Change kore_buf_append() and kore_buf_replace_string() to take a void pointer. --- includes/kore.h | 4 ++-- src/buf.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/includes/kore.h b/includes/kore.h index 01d6a96..28d2e95 100644 --- a/includes/kore.h +++ b/includes/kore.h @@ -343,13 +343,13 @@ void net_send_queue(struct connection *, u_int8_t *, size_t, int, void kore_buf_free(struct kore_buf *); struct kore_buf *kore_buf_create(u_int32_t); -void kore_buf_append(struct kore_buf *, u_int8_t *, u_int32_t); +void kore_buf_append(struct kore_buf *, void *, u_int32_t); u_int8_t *kore_buf_release(struct kore_buf *, u_int32_t *); void kore_buf_appendf(struct kore_buf *, const char *, ...); void kore_buf_appendv(struct kore_buf *, struct buf_vec *, u_int16_t); void kore_buf_appendb(struct kore_buf *, struct kore_buf *); void kore_buf_replace_string(struct kore_buf *, const char *, - u_int8_t *, size_t); + void *, size_t); struct spdy_header_block *spdy_header_block_create(int); struct spdy_stream *spdy_stream_lookup(struct connection *, u_int32_t); diff --git a/src/buf.c b/src/buf.c index 1e19984..827b042 100644 --- a/src/buf.c +++ b/src/buf.c @@ -30,7 +30,7 @@ kore_buf_create(u_int32_t initial) } void -kore_buf_append(struct kore_buf *buf, u_int8_t *d, u_int32_t len) +kore_buf_append(struct kore_buf *buf, void *d, u_int32_t len) { if ((buf->offset + len) >= buf->length) { buf->length += len + KORE_BUF_INCREMENT; @@ -99,7 +99,7 @@ kore_buf_free(struct kore_buf *buf) void kore_buf_replace_string(struct kore_buf *b, const char *src, - u_int8_t *dst, size_t len) + void *dst, size_t len) { u_int32_t blen, off, off2; size_t nlen, klen;