Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re^4: Opens but Won't Write to file

by ikegami (Pope)
on Oct 30, 2009 at 22:16 UTC ( #804227=note: print w/ replies, xml ) Need Help??


in reply to Re^3: Opens but Won't Write to file
in thread Opens but Won't Write to file

Actually, the OP already has IO::Handle loaded (via IO::Socket via IO::Socket::INET), so it's free for him.

For others, it has a one-time cost of 100ms.

>perl -le"use Time::HiRes qw( time ); $stime=time; require IO::Handle; + $etime=time; print $etime-$stime;" 0.082003116607666 >perl -le"use Time::HiRes qw( time ); $stime=time; require IO::Handle; + $etime=time; print $etime-$stime;" 0.0974130630493164 >perl -le"use Time::HiRes qw( time ); $stime=time; require IO::Handle; + $etime=time; print $etime-$stime;" 0.120858192443848

It's up to them if that's acceptable or not. If it's not, I suggest copying autoflush out of IO::Handle and call it as follows rather than twiddling with select and $| directly.

autoflush(HANDLE, 1);


Comment on Re^4: Opens but Won't Write to file
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://804227]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (15)
As of 2015-07-31 16:04 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (279 votes), past polls