>From 94f9340cab36ff9236b737159ba8212d8f58bfab Mon Sep 17 00:00:00 2001 From: Lukas Slebodnik Date: Tue, 10 Nov 2015 10:16:46 +0100 Subject: [PATCH] Ticket #48257 - Fix coverity issues - 08/24/2015 Description: Remove extra curly brace and fix indentation of related code Introduced by commit 4b9a54f7ba5f78b0402c0695998cca049ea3f095. src/ringbuffer/ringbuffer_get_and_put.c:17:3: warning: control may reach end of non-void function [-Wreturn-type] } ^ src/ringbuffer/ringbuffer_get_and_put.c:19:18: error: unknown type name 'rs' queue_dequeue( rs->qs, (void **) fe ); ^ src/ringbuffer/ringbuffer_get_and_put.c:19:20: error: expected ')' queue_dequeue( rs->qs, (void **) fe ); ^ src/ringbuffer/ringbuffer_get_and_put.c:19:16: note: to match this '(' queue_dequeue( rs->qs, (void **) fe ); ^ src/ringbuffer/ringbuffer_get_and_put.c:19:3: warning: type specifier missing, defaults to 'int' [-Wimplicit-int] queue_dequeue( rs->qs, (void **) fe ); ^ src/ringbuffer/ringbuffer_get_and_put.c:21:3: error: expected identifier or '(' return( *fe ); ^ src/ringbuffer/ringbuffer_get_and_put.c:22:1: error: extraneous closing brace ('}') } ^ 2 warnings and 4 errors generated. Signed-off-by: Lukas Slebodnik --- liblfds/src/ringbuffer/ringbuffer_get_and_put.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/liblfds/src/ringbuffer/ringbuffer_get_and_put.c b/liblfds/src/ringbuffer/ringbuffer_get_and_put.c index 625ed6e23020645b352824b01f0ad9cb74cbc8be..24f7a4a2092d296cd02b6680747f5a0ca60d36e2 100644 --- a/liblfds/src/ringbuffer/ringbuffer_get_and_put.c +++ b/liblfds/src/ringbuffer/ringbuffer_get_and_put.c @@ -12,8 +12,7 @@ struct freelist_element *ringbuffer_get_read_element( struct ringbuffer_state *r assert( rs != NULL ); assert( fe != NULL ); #endif - return NULL; - } + return NULL; } queue_dequeue( rs->qs, (void **) fe ); -- 2.5.0