From: <db...@CT...> - 2003-07-07 15:16:03
|
For what it's worth, I only get one print of the string instead of two on both my setups, which are as follows: Setup #1: OS=Redhat Linux 7.3 IO::Tty= version 1.02 Perl=5.6.1 Expect.pm= 1.15 Setup #2: OS=Solaris 7 (Sparc 4500) IO::Tty= version 1.02 Perl=5.8.0 Expect.pm= 1.15 Chris Muth <mut...@mc...> Sent by: To: Exp...@li... exp...@li...urc cc: eforge.net Subject: [Expectperl-discuss] Double prints to screen from one print statement? 07/06/2003 09:47 PM 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 ------------------------------------------------------- This SF.Net email sponsored by: Free pre-built ASP.NET sites including Data Reports, E-commerce, Portals, and Forums are available now. Download today and enter to win an XBOX or Visual Studio .NET. http://aspnet.click-url.com/go/psa00100006ave/direct;at.asp_061203_01/01 _______________________________________________ Expectperl-discuss mailing list Exp...@li... https://lists.sourceforge.net/lists/listinfo/expectperl-discuss |