From your other response, I suspect the problem isn't related to buffering, contrary to what you've titled your node.
Your code will only print a line if your getIDnumber sub returns a true value. Are you sure that the last lines of your input start with a > character (with nothing intervening)? Otherwise the sub will return an empty string, which represents falsehood in Perl, which will cause your program to not print anything.
You said it works when you open and close the filehandle, but how are you doing that? Is the variable $ID_LIMIT involved? (You should be getting a "used only once" warning on that one. ;-) My suspicion is that it's something incidental to how you're doing the close and re-open. Maybe if you posted that other code, the bug would be easier to spot.
In reply to Re: Buffering File Output
by VSarkiss
in thread Buffering File Output
by MadraghRua
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |