From 075e6e73d5e48ec72e1fc6d164bc77325e8b298f Mon Sep 17 00:00:00 2001 From: TheDarkBug <41623496+TheDarkBug@users.noreply.github.com> Date: Sun, 1 Aug 2021 11:32:39 +0200 Subject: [PATCH] Fixed #121 parse_config will be called before reading the arguments, just like get_info --- uwufetch.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/uwufetch.c b/uwufetch.c index 94c79ea..4364f24 100644 --- a/uwufetch.c +++ b/uwufetch.c @@ -124,6 +124,7 @@ int main(int argc, char *argv[]) {"list", no_argument, NULL, 'l'}, {NULL, 0, NULL, 0}}; get_info(); + parse_config(); while ((opt = getopt_long(argc, argv, "ac:d:hi::l", long_options, NULL)) != -1) { switch (opt) @@ -155,8 +156,6 @@ int main(int argc, char *argv[]) break; } } - if (argc == 1) - parse_config(); if ((argc == 1 && ascii_image_flag == 0) || (argc > 1 && ascii_image_flag == 0)) { printf("\n"); // print a new line