This commit is contained in:
Michal Utľák 2024-04-09 16:40:49 +02:00
parent 710956e0df
commit 6f4ea44c71

View File

@ -2,7 +2,7 @@
#include <stdlib.h>
struct snake* add_snake(struct snake* snake,int x,int y){
struct snake* hlavicka = (struct snake*)malloc(sizeof(struct snake));
struct snake* hlavicka = calloc(1,sizeof(struct snake));
if (hlavicka == NULL) {
return NULL;
}