in reply to Non buffered telnet?
However, you noted that you'll be further editing the data before you're done with it, and also I get the sense that memory seems to be a primary concern in the issue.open(OUTPUT, '>output.file'); while($tel->recv($buffer, 512)) { print OUTPUT $buffer; } close OUTPUT;
Now, all of the output from your telnet session has been stored in the $output temporary file which you can use for further parsing and editing.my $output = IO::File->new_tmpfile(); while($tel->recv($buffer, 512)) { $output->print($buffer); }
|
|---|