Correct warning if used -Wextra

This commit is contained in:
german 2026-05-03 19:50:29 +04:00
parent 3b8246dd44
commit fc6afeda5b

View File

@ -144,7 +144,7 @@ static unsigned char __compile_and_equals_sflag(char* flags, char* str) {
} }
static char* malloc_str(char* str) { static char* malloc_str(char* str) {
char* ptr = malloc((strlen(str)) * sizeof(char) + sizeof(char)); char* ptr = (char*)malloc((strlen(str)) * sizeof(char) + sizeof(char));
strcpy(ptr, str); strcpy(ptr, str);
return ptr; return ptr;
} }