diff options
author | graehl <graehl@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-07-16 20:42:45 +0000 |
---|---|---|
committer | graehl <graehl@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-07-16 20:42:45 +0000 |
commit | 4d4dec33b67eb92793bd73b2f193cd99ed021319 (patch) | |
tree | f32c7310e21d4be55f7ad9d4f743d4bae7723a8b | |
parent | a4edcaaa4e22691effc8a1535150117dc7a75e0a (diff) |
cmdline parsing
git-svn-id: https://ws10smt.googlecode.com/svn/trunk@293 ec762483-ff6d-05da-a07a-a48fb63a330f
-rwxr-xr-x | vest/line_mediator.pl | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/vest/line_mediator.pl b/vest/line_mediator.pl index 87a73590..acb9a036 100755 --- a/vest/line_mediator.pl +++ b/vest/line_mediator.pl @@ -19,7 +19,7 @@ my @c1; if (scalar @ARGV) { do { push @c1,shift - } while $c1[$#c1] ne '--'; + } while scalar @ARGV && $c1[$#c1] ne '--'; } pop @c1; my @c2=@ARGV; @@ -54,12 +54,10 @@ if ($serial || $snake) { } else { while(<$R1>) { info("1:",$_); - select $W2; - $|=1; - print $_; + lineto($W2,$_); last unless defined ($_=<$R2>); info("2:",$_); - print $W1 $_; + lineto($W1,$_); } } } else { |