From f7d61b0bbf586b4566b6dbf96dc9bea8378a66c7 Mon Sep 17 00:00:00 2001 From: Yurii Yakovenko Date: Mon, 11 Nov 2024 23:03:54 +0000 Subject: [PATCH] Update cv7/program.c --- cv7/program.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/cv7/program.c b/cv7/program.c index 453347c..5128db9 100644 --- a/cv7/program.c +++ b/cv7/program.c @@ -21,7 +21,7 @@ struct tree* read_tree() memset(buffer,0,SIZE); char* r = fgets(buffer,SIZE,stdin); - assert(r); + if(r==NULL) return NULL; if(buffer[0]=='\n') return NULL; @@ -140,4 +140,3 @@ int main(void) } -