in reply to Re: How to trace a dying process
in thread How to trace a dying process

Works fine for me:
while (<>) { print "got $_"; }
1 got 1 2 got 2 0 got 0 5 got 5
Update: see perlop2:

In these loop constructs, the assigned value (whether assignment is automatic or explicit) is then tested to see if it is defined. The defined test avoids problems where line has a string value that would be treated as false by perl e.g. ``'' or ``0'' with no trailing newline.