Fixed recursion segfault (on my system works)

This commit is contained in:
TheDarkBug 2021-10-03 13:51:05 +02:00
parent f1ef095a9c
commit 047dbb49f9

View file

@ -188,9 +188,10 @@ void parse_config()
// opening and reading the config file // opening and reading the config file
FILE *config; FILE *config;
if (config_directory == NULL) if (config_directory == NULL) {
if (homedir != NULL) if (homedir != NULL)
config = fopen(strcat(homedir, "/.config/uwufetch/config"), "r"); config = fopen(strcat(homedir, "/.config/uwufetch/config"), "r");
}
else else
config = fopen(config_directory, "r"); config = fopen(config_directory, "r");
if (config == NULL) if (config == NULL)
@ -738,7 +739,7 @@ void replace_ignorecase(char *original, char *search, char *replacer)
original[0] = 0; original[0] = 0;
strcpy(original, buffer); strcpy(original, buffer);
replace(original, search, replacer); replace(original, search, replacer);
return replace_ignorecase(original, search, replacer); return replace(original, search, replacer);
} }
void print_ascii() void print_ascii()