From 4c50b345c59df3a7860c4dfab8adfd0e24fd4f25 Mon Sep 17 00:00:00 2001 From: Haden Collins Date: Mon, 22 Apr 2024 15:51:21 -0500 Subject: [PATCH] Minor style changes --- main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main.c b/main.c index 76f69ee..1031af6 100644 --- a/main.c +++ b/main.c @@ -94,11 +94,10 @@ static const char *help = static gboolean process_args(int argc, char *argv[]) { - int c; while (TRUE) { int option_index = 0; - c = getopt_long(argc, argv, "hl:vc:m:b:T:R:L:B:r:c:p:C:sP:n", + int c = getopt_long(argc, argv, "hl:vc:m:b:T:R:L:B:r:c:p:C:sP:n", long_options, &option_index); if (c == -1) { @@ -342,6 +341,7 @@ static gboolean get_buttons(FILE *json) jsmntok_t *tok = malloc(default_size * sizeof(jsmntok_t)); if (!tok) { + free(buffer); g_warning("Failed to allocate memory\n"); return TRUE; }