From: Marek Küthe Date: Tue, 12 Dec 2023 15:06:17 +0000 (+0000) Subject: Correct a type mismatch X-Git-Url: https://git.tinc-vpn.org/git/browse?a=commitdiff_plain;h=6e6dcbc7e77fbc4f7873b6e40c911b7038a6a648;p=tinc Correct a type mismatch In one place in the source code, the debug level of type `int` was used and in other places of type `debug_t`. This commit introduces a change so that the type `debug_t` is used in both places. This also resolves a compiler warning. Signed-off-by: Marek Küthe --- diff --git a/src/info.c b/src/info.c index 25e6b60c..69d29c12 100644 --- a/src/info.c +++ b/src/info.c @@ -26,7 +26,7 @@ #include "tincctl.h" #include "utils.h" -void logger(int level, int priority, const char *format, ...) { +void logger(debug_t level, int priority, const char *format, ...) { (void)level; (void)priority; va_list ap; diff --git a/src/tincctl.c b/src/tincctl.c index 3b7efd4e..3af0f1f8 100644 --- a/src/tincctl.c +++ b/src/tincctl.c @@ -80,7 +80,7 @@ char *scriptextension = defaultextension; static char *prompt; char *device = NULL; char *iface = NULL; -int debug_level = -1; +debug_t debug_level = -1; typedef enum option_t { OPT_BAD_OPTION = '?',