Allow reading from interface without additional script arguments.

Reading from an interface like `bro -i en0` no longer expects to
start reading stdin for a script to load.  Explicitly passing in
'-' as an additional command line argument still allows reading a
script from stdin.

Closes #561
This commit is contained in:
Jon Siwek 2011-08-17 20:38:20 -05:00
parent 2e8a70a662
commit bc1c3ea28a

View file

@ -688,6 +688,7 @@ int main(int argc, char** argv)
if ( optind == argc && if ( optind == argc &&
read_files.length() == 0 && flow_files.length() == 0 && read_files.length() == 0 && flow_files.length() == 0 &&
interfaces.length() == 0 &&
! (id_name || bst_file) && ! command_line_policy ) ! (id_name || bst_file) && ! command_line_policy )
add_input_file("-"); add_input_file("-");