From 29d6cdbc6cbe44a25bbfb351f84116108a833366 Mon Sep 17 00:00:00 2001 From: Pavel Charvat Date: Sun, 26 Feb 2017 23:56:38 +0100 Subject: [PATCH] Opt: Fixed compilation warnings in tests. --- ucw/opt-test.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ucw/opt-test.c b/ucw/opt-test.c index 07fd6835..1ff0f6cf 100644 --- a/ucw/opt-test.c +++ b/ucw/opt-test.c @@ -14,7 +14,7 @@ #include #include -static void show_version(struct opt_item * opt UNUSED, const char * value UNUSED, void * data UNUSED) { +static void show_version(const struct opt_item * opt UNUSED, const char * value UNUSED, void * data UNUSED) { printf("This is a simple tea boiling console v0.1.\n"); exit(EXIT_SUCCESS); } @@ -56,7 +56,7 @@ static char * first_tea = NULL; #define MAX_TEA_COUNT 30 static char * tea_list[MAX_TEA_COUNT]; static int tea_num = 0; -static void add_tea(struct opt_item * opt UNUSED, const char * name, void * data) { +static void add_tea(const struct opt_item * opt UNUSED, const char * name, void * data) { char ** tea_list = data; if (tea_num >= MAX_TEA_COUNT) { fprintf(stderr, "Cannot boil more than %d teas.\n", MAX_TEA_COUNT); @@ -100,7 +100,7 @@ static struct cf_user_type teapot_temperature_t = { .dumper = (cf_dumper1*) teapot_temperature_dumper }; -static void opt_test_hook(struct opt_item * opt, uint event UNUSED, const char * value, void * data) { +static void opt_test_hook(const struct opt_item * opt, uint event UNUSED, const char * value, void * data) { if (!show_hooks) return; if (opt) -- 2.39.2