From fdd4aef34003587d7fd9ed754dd35ce901b639bf Mon Sep 17 00:00:00 2001 From: Thomas Jarosch Date: Mon, 5 Jan 2015 18:44:36 +0100 Subject: Make thirty functions static to reduce binary size If any of those functions should be (unused) API functions, they can easily be turned back once really needed. Detected using a new cppcheck check that uses the internal symbol database to catch functions that are only used in the current file. Change-Id: Ic2b1e5b8020b76397f11cefc4e205f3b7ac1f184 --- lib/skin_parser/skin_parser.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lib/skin_parser/skin_parser.c') diff --git a/lib/skin_parser/skin_parser.c b/lib/skin_parser/skin_parser.c index a26e6ce474..b5ad023d0a 100644 --- a/lib/skin_parser/skin_parser.c +++ b/lib/skin_parser/skin_parser.c @@ -1142,7 +1142,7 @@ static struct skin_element* skin_parse_code_as_arg(const char** document) } /* Memory management */ -struct skin_element* skin_alloc_element() +static struct skin_element* skin_alloc_element() { struct skin_element* retval = (struct skin_element*) skin_buffer_alloc(sizeof(struct skin_element)); @@ -1164,7 +1164,7 @@ struct skin_element* skin_alloc_element() * enough for any tag. params should be used straight away by the callback * so this is safe. */ -struct skin_tag_parameter* skin_alloc_params(int count) +static struct skin_tag_parameter* skin_alloc_params(int count) { size_t size = sizeof(struct skin_tag_parameter) * count; return (struct skin_tag_parameter*)skin_buffer_alloc(size); @@ -1176,7 +1176,7 @@ char* skin_alloc_string(int length) return (char*)skin_buffer_alloc(sizeof(char) * (length + 1)); } -OFFSETTYPE(struct skin_element*)* skin_alloc_children(int count) +static OFFSETTYPE(struct skin_element*)* skin_alloc_children(int count) { return (OFFSETTYPE(struct skin_element*)*) skin_buffer_alloc(sizeof(struct skin_element*) * count); -- cgit v1.2.3