Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re^2: Safely reading line by line

by moritz (Cardinal)
on Jun 27, 2007 at 12:38 UTC ( [id://623606]=note: print w/replies, xml ) Need Help??


in reply to Re: Safely reading line by line
in thread Safely reading line by line

Your post was helpful indeed, but there is a thing to consider (and the reason for me to propose crashing the interpreter ;-)

If you read data line by line, that's usually because you need it line by line.

Depending on your application it might be possible to handle incomplete lines without much change to your program, or it might not.

If there is a good reason for line based reading, and the line doesn't fit into RAM, you're lost anyway. (Not always, but still rather often).

On the other hand if the line based reading is just a method of chunking the data, then the approach that uses a read limit is probably the way to go.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others rifling through the Monastery: (5)
As of 2024-04-18 06:13 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found