Replaced with (line 180), trying to fix #43

This commit is contained in:
TheDarkBug 2021-03-17 10:38:48 +01:00
parent 20958b6118
commit 596b2ce458
2 changed files with 2 additions and 2 deletions

View file

@ -8,7 +8,7 @@ build: uwufetch.c
gcc $(FLAGS) -o $(NAME) $(FILES) gcc $(FLAGS) -o $(NAME) $(FILES)
debug: debug:
clear @clear
gcc $(FLAGS_DEBUG) -o $(NAME) $(FILES) gcc $(FLAGS_DEBUG) -o $(NAME) $(FILES)
./uwufetch ./uwufetch

View file

@ -177,7 +177,7 @@ void get_info() { // get all necessary info
fclose(cpuinfo); fclose(cpuinfo);
gethostname(host, 256); gethostname(host, 256);
sscanf(getenv("SHELL"), "%s", shell); sscanf(getenv("SHELL"), "%s", shell);
if (strlen(shell) > 16) memmove(&shell, &shell[27], sizeof(shell)); // android shell was too long, this works only for termux if (strlen(shell) > 16) memmove(&shell, &shell[27], strlen(shell)); // android shell was too long, this works only for termux
// system resources // system resources
uname(&sys_var); uname(&sys_var);