changeset 19563:65f4d9e1206c

Don't check for input redirect in combination with --eval or script. isatty is not reentrant and doesn't always give correct results when there are multiple concurrent instances of octave such as with make -j4. * octave.cc (octave_process_command_line): Remove code using isatty to check for input redirection.
author Rik <rik@octave.org>
date Sat, 03 Jan 2015 09:52:07 -0800
parents 4f615cd9a68d
children 5ab6fcf32d1e
files libinterp/octave.cc
diffstat 1 files changed, 0 insertions(+), 16 deletions(-) [+]
line wrap: on
line diff
--- a/libinterp/octave.cc	Sat Jan 03 17:57:54 2015 +0100
+++ b/libinterp/octave.cc	Sat Jan 03 09:52:07 2015 -0800
@@ -711,22 +711,6 @@
       octave_print_terse_usage_and_exit ();
     }
 
-  bool redir_input = ! gnulib::isatty (fileno (stdin));
-
-  if (! code_to_eval.empty () && redir_input)
-    {
-      error ("--eval \"CODE\" and '< script' are mutually exclusive options");
-
-      octave_print_terse_usage_and_exit ();
-    }
- 
-  if (script_file && redir_input)
-    {
-      error ("script file and '< script' are mutually exclusive options");
-
-      octave_print_terse_usage_and_exit ();
-    }
-
 }
 
 // EMBEDDED is declared int instead of bool because this function is