3226
3227 - fix several eof bugs with stream input

It's possible I'm wrong to not let read signal eof in some unambiguous
manner.