From b54643650e0e83c11938ba3c60800ba7aea00993 Mon Sep 17 00:00:00 2001 From: Maryna Kravtsova Date: Sun, 22 Nov 2020 17:09:49 +0100 Subject: [PATCH] buffet --- cv8/program.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/cv8/program.c b/cv8/program.c index c82a6cb..c620766 100644 --- a/cv8/program.c +++ b/cv8/program.c @@ -43,11 +43,11 @@ void search(struct tree* this){ if(fgets(buffer, 5, stdin) == NULL){ printf("Koniec vstupu\n"); return; - } - //char* r = fgets(buffer,5,stdin); - //int x = strlen(buffer); - //buffer[x-1]='\0'; - + } + if(buffer[0] == '\n'){ + printf("Koniec vstupu\n"); + return; + } if(buffer[0] == '\n'){ char* r = fgets(buffer,5,stdin); }