From: Chris M. <mut...@mc...> - 2003-07-07 01:48:53
|
Hey, I have been having trouble with print statements in my perl scripts printing to the screen twice. They are just standard print statements to STDOUT, not much to do with Expect. As seen in the fragment below the print before the call to spawn() will get be seen in the output twice, and the one below will be seen in the output once. Is this a bug, or is this just an idiosyncrasy that one must simply make allowances for? Thanks, Chris #!/usr/bin/perl -w # # use Expect; $exp = new Expect; $exp->raw_pty(1); # Above spawn() we see it twice. print "<you will see this string twice >"; $exp->spawn("/bin/ls"); # Below spawn() we see it once. print "<you will see this string once >"; print "\n"; # EOF |