From 41160ed4bc79c5f58049f5112eb176a906fe7db1 Mon Sep 17 00:00:00 2001 From: Dimitri Staessens Date: Tue, 23 Feb 2016 17:08:33 +0100 Subject: lib: fixed build errors in du_buff du_buff.c is now compliant with more stringent compiler flags --- src/lib/du_buff.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/lib/du_buff.c b/src/lib/du_buff.c index 84bf528c..e4b56b5b 100644 --- a/src/lib/du_buff.c +++ b/src/lib/du_buff.c @@ -116,11 +116,10 @@ struct buffer * buffer_create (size_t size) struct buffer * buffer_seek(const struct buffer * head, size_t pos) { struct list_head * ptr = NULL; - struct buffer * hit = NULL; size_t cur_buf_start = 0; size_t cur_buf_end = 0; - if (head = NULL) { + if (head == NULL) { LOG_DBGF("Bogus input, bugging out."); return NULL; } @@ -142,11 +141,10 @@ struct buffer * buffer_seek(const struct buffer * head, size_t pos) uint8_t * buffer_seek_pos(const struct buffer * head, size_t pos) { struct list_head * ptr = NULL; - struct buffer * hit = NULL; size_t cur_buf_start = 0; size_t cur_buf_end = 0; - if (head = NULL) { + if (head == NULL) { LOG_DBGF("Bogus input, bugging out."); return NULL; } @@ -273,7 +271,6 @@ int du_buff_init(du_buff_t * dub, dub->du_end = start + len; return buffer_copy_data(dub->buffer, start, data, len); - } uint8_t * du_buff_data_ptr_start(du_buff_t * dub) -- cgit v1.2.3