recursive_compiler.c
changeset 131 b5ad49852adc
parent 77 49e0babccb23
--- a/recursive_compiler.c
+++ b/recursive_compiler.c
@@ -98,7 +98,8 @@
 int main (int argc, char **argv)
 {
     printf ("Bitte geben Sie einen Ausdruck in Infix-Notation ein:\n\n\t");
-    fgets (expression, MAX, stdin);
+    if (fgets (expression, MAX, stdin) == NULL)
+        return EXIT_FAILURE;
 
     printf ("\nCompilierter Ausdruck in Postfix-Notation:\n\n\t");
     compile_mode = MODE_POSTFIX;