This commit is contained in:
Michal Utľák 2024-04-23 19:40:18 +02:00
parent 447d5f0f6c
commit 6073724ccc

View File

@ -13,7 +13,8 @@ node_t *build_tree(int *tree_data, size_t tree_data_len){
if(tree_data != NULL && tree_data_len != 0){
koren->data = tree_data[0];
koren->left = (node_t *)tree_data[0];
koren->left = (node_t *)malloc(sizeof(node_t));
koren->left->data = tree_data[0];
}
return koren;