Since I needed something like this, I decided to create something reasonably efficient and wrap it up as a CPAN module.
http://search.cpan.org/~robm/File-GetLineMaxLength/
Someone wrote a review as well here File::GetLineMaxLength, the infinite loop bug + README file issues have been fixed since 1.01.
In reply to Re: Read a line with max length ?
by robmueller
in thread Read a line with max length ?
by fauxpas
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |