From 9af1c10430e565c42000cbe559029bee5ebd681a Mon Sep 17 00:00:00 2001 From: Lee Date: Mon, 7 Jan 2019 00:17:08 -0500 Subject: [PATCH] fix cppcheck warnings in cgisimple.c [cgisimple.c:308]: (warning) %u in format string (no. 2) requires 'unsigned int' but the argument type is 'signed int'. [cgisimple.c:404]: (warning) %d in format string (no. 1) requires 'int' but the argument type is 'unsigned int'. --- cgisimple.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cgisimple.c b/cgisimple.c index 79b811f9..5711087e 100644 --- a/cgisimple.c +++ b/cgisimple.c @@ -308,7 +308,7 @@ static void cgi_create_client_tag_form(char *form, size_t size, snprintf(form, size, "
\n" " \n" - " \n" + " \n" " \n" " \n" "
", tag, toggle_state, !expires, button_name); @@ -401,7 +401,7 @@ jb_err cgi_show_client_tags(struct client_state *csp, refresh_delay = get_next_tag_timeout_for_client(csp->client_address); if (refresh_delay != 0) { - snprintf(buf, sizeof(buf), "%d", csp->config->client_tag_lifetime); + snprintf(buf, sizeof(buf), "%u", csp->config->client_tag_lifetime); if (map(exports, "refresh-delay", 1, buf, 1)) { free_map(exports); -- 2.49.0