diff options
author | jan Iversen <jani@libreoffice.org> | 2018-05-22 09:07:42 +0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2018-05-24 08:34:14 -0700 |
commit | 061be82e31f0d08804cd5d0edc2244540200fcea (patch) | |
tree | 94f0e5da65bab561200f9be245e25c507d6be850 /core/parse-xml.c | |
parent | 6e253fa04f81be6fb26ff59cd5be39c85bfe3d19 (diff) | |
download | subsurface-061be82e31f0d08804cd5d0edc2244540200fcea.tar.gz |
core: replace (void) with UNUSED(x) and include ssrf.h
Unused parameters in C are "silenced" by adding UNUSED(x)
Signed-off-by: Jan Iversen <jani@apache.org>
Diffstat (limited to 'core/parse-xml.c')
-rw-r--r-- | core/parse-xml.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/core/parse-xml.c b/core/parse-xml.c index c2b8b26c9..ff9fa2421 100644 --- a/core/parse-xml.c +++ b/core/parse-xml.c @@ -4,6 +4,7 @@ #pragma clang diagnostic ignored "-Wmissing-field-initializers" #endif +#include "ssrf.h" #include <stdio.h> #include <ctype.h> #include <string.h> @@ -404,8 +405,8 @@ static void gasmix(char *buffer, fraction_t *fraction) static void gasmix_nitrogen(char *buffer, struct gasmix *gasmix) { - (void) buffer; - (void) gasmix; + UNUSED(buffer); + UNUSED(gasmix); /* Ignore n2 percentages. There's no value in them. */ } @@ -925,7 +926,7 @@ static void try_to_fill_sample(struct sample *sample, const char *name, char *bu static void try_to_fill_userid(const char *name, char *buf) { - (void) name; + UNUSED(name); if (prefs.save_userid_local) set_userid(buf); } @@ -1606,7 +1607,7 @@ static const char *preprocess_divelog_de(const char *buffer) int parse_xml_buffer(const char *url, const char *buffer, int size, struct dive_table *table, const char **params) { - (void) size; + UNUSED(size); xmlDoc *doc; const char *res = preprocess_divelog_de(buffer); int ret = 0; |