Merge pull request #554 from dsnet/master

Properly handle io.EOF error conditions when reading