Fixed small inconsistency in handling EOF among receive functions. Now all functions always drop the ready flag in this case.