du5
This commit is contained in:
parent
37816a8709
commit
8352be6eb9
@ -18,7 +18,8 @@ Tree* readTree() {
|
||||
if (fgets(line, SIZE, stdin) == NULL) return NULL;
|
||||
|
||||
// якщо пустий рядок → кінець бази
|
||||
if (strcmp(line, "\n") == 0) return NULL;
|
||||
line[strcspn(line, "\r\n")] = 0;
|
||||
if (line[0] == '\0') return NULL;
|
||||
|
||||
Tree *node = malloc(sizeof(Tree));
|
||||
node->yes = NULL;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user